back_recharge
zhangshanxue 2020-05-20 10:31:39 +08:00
commit c332a9b8c3
24 changed files with 603 additions and 138 deletions

View File

@ -10,6 +10,24 @@ public final class Expedition {
} }
public interface GetExpeditionRequestOrBuilder public interface GetExpeditionRequestOrBuilder
extends com.google.protobuf.MessageOrBuilder { 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} * Protobuf type {@code com.ljsd.jieling.protocols.GetExpeditionRequest}
@ -48,6 +66,7 @@ public final class Expedition {
com.google.protobuf.ExtensionRegistryLite extensionRegistry) com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException { throws com.google.protobuf.InvalidProtocolBufferException {
initFields(); initFields();
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder(); com.google.protobuf.UnknownFieldSet.newBuilder();
try { try {
@ -65,6 +84,11 @@ public final class Expedition {
} }
break; break;
} }
case 8: {
bitField0_ |= 0x00000001;
leve_ = input.readInt32();
break;
}
} }
} }
} catch (com.google.protobuf.InvalidProtocolBufferException e) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
@ -104,7 +128,33 @@ public final class Expedition {
return PARSER; 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() { private void initFields() {
leve_ = 0;
} }
private byte memoizedIsInitialized = -1; private byte memoizedIsInitialized = -1;
public final boolean isInitialized() { public final boolean isInitialized() {
@ -118,6 +168,9 @@ public final class Expedition {
public void writeTo(com.google.protobuf.CodedOutputStream output) public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException { throws java.io.IOException {
getSerializedSize(); getSerializedSize();
if (((bitField0_ & 0x00000001) == 0x00000001)) {
output.writeInt32(1, leve_);
}
getUnknownFields().writeTo(output); getUnknownFields().writeTo(output);
} }
@ -127,6 +180,10 @@ public final class Expedition {
if (size != -1) return size; if (size != -1) return size;
size = 0; size = 0;
if (((bitField0_ & 0x00000001) == 0x00000001)) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(1, leve_);
}
size += getUnknownFields().getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size; memoizedSerializedSize = size;
return size; return size;
@ -247,6 +304,8 @@ public final class Expedition {
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
leve_ = 0;
bitField0_ = (bitField0_ & ~0x00000001);
return this; return this;
} }
@ -273,6 +332,13 @@ public final class Expedition {
public com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest buildPartial() { public com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest buildPartial() {
com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest result = new com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest(this); 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(); onBuilt();
return result; return result;
} }
@ -288,6 +354,9 @@ public final class Expedition {
public Builder mergeFrom(com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest other) { public Builder mergeFrom(com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest other) {
if (other == com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest.getDefaultInstance()) return this; if (other == com.ljsd.jieling.protocols.Expedition.GetExpeditionRequest.getDefaultInstance()) return this;
if (other.hasLeve()) {
setLeve(other.getLeve());
}
this.mergeUnknownFields(other.getUnknownFields()); this.mergeUnknownFields(other.getUnknownFields());
return this; return this;
} }
@ -313,6 +382,56 @@ public final class Expedition {
} }
return this; 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) // @@protoc_insertion_point(builder_scope:com.ljsd.jieling.protocols.GetExpeditionRequest)
} }
@ -2159,23 +2278,23 @@ public final class Expedition {
public interface TakeExpeditionBoxRewardRequestOrBuilder public interface TakeExpeditionBoxRewardRequestOrBuilder
extends com.google.protobuf.MessageOrBuilder { 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> * <pre>
* *id
* </pre> * </pre>
*/ */
boolean hasLay(); boolean hasLaycfg();
/** /**
* <code>optional int32 lay = 1;</code> * <code>optional int32 laycfg = 1;</code>
* *
* <pre> * <pre>
* *id
* </pre> * </pre>
*/ */
int getLay(); int getLaycfg();
} }
/** /**
* Protobuf type {@code com.ljsd.jieling.protocols.TakeExpeditionBoxRewardRequest} * Protobuf type {@code com.ljsd.jieling.protocols.TakeExpeditionBoxRewardRequest}
@ -2230,7 +2349,7 @@ public final class Expedition {
} }
case 8: { case 8: {
bitField0_ |= 0x00000001; bitField0_ |= 0x00000001;
lay_ = input.readInt32(); laycfg_ = input.readInt32();
break; break;
} }
} }
@ -2273,32 +2392,32 @@ public final class Expedition {
} }
private int bitField0_; private int bitField0_;
// optional int32 lay = 1; // optional int32 laycfg = 1;
public static final int LAY_FIELD_NUMBER = 1; public static final int LAYCFG_FIELD_NUMBER = 1;
private int lay_; private int laycfg_;
/** /**
* <code>optional int32 lay = 1;</code> * <code>optional int32 laycfg = 1;</code>
* *
* <pre> * <pre>
* *id
* </pre> * </pre>
*/ */
public boolean hasLay() { public boolean hasLaycfg() {
return ((bitField0_ & 0x00000001) == 0x00000001); return ((bitField0_ & 0x00000001) == 0x00000001);
} }
/** /**
* <code>optional int32 lay = 1;</code> * <code>optional int32 laycfg = 1;</code>
* *
* <pre> * <pre>
* *id
* </pre> * </pre>
*/ */
public int getLay() { public int getLaycfg() {
return lay_; return laycfg_;
} }
private void initFields() { private void initFields() {
lay_ = 0; laycfg_ = 0;
} }
private byte memoizedIsInitialized = -1; private byte memoizedIsInitialized = -1;
public final boolean isInitialized() { public final boolean isInitialized() {
@ -2313,7 +2432,7 @@ public final class Expedition {
throws java.io.IOException { throws java.io.IOException {
getSerializedSize(); getSerializedSize();
if (((bitField0_ & 0x00000001) == 0x00000001)) { if (((bitField0_ & 0x00000001) == 0x00000001)) {
output.writeInt32(1, lay_); output.writeInt32(1, laycfg_);
} }
getUnknownFields().writeTo(output); getUnknownFields().writeTo(output);
} }
@ -2326,7 +2445,7 @@ public final class Expedition {
size = 0; size = 0;
if (((bitField0_ & 0x00000001) == 0x00000001)) { if (((bitField0_ & 0x00000001) == 0x00000001)) {
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeInt32Size(1, lay_); .computeInt32Size(1, laycfg_);
} }
size += getUnknownFields().getSerializedSize(); size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size; memoizedSerializedSize = size;
@ -2444,7 +2563,7 @@ public final class Expedition {
public Builder clear() { public Builder clear() {
super.clear(); super.clear();
lay_ = 0; laycfg_ = 0;
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000001);
return this; return this;
} }
@ -2477,7 +2596,7 @@ public final class Expedition {
if (((from_bitField0_ & 0x00000001) == 0x00000001)) { if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
to_bitField0_ |= 0x00000001; to_bitField0_ |= 0x00000001;
} }
result.lay_ = lay_; result.laycfg_ = laycfg_;
result.bitField0_ = to_bitField0_; result.bitField0_ = to_bitField0_;
onBuilt(); onBuilt();
return result; return result;
@ -2494,8 +2613,8 @@ public final class Expedition {
public Builder mergeFrom(com.ljsd.jieling.protocols.Expedition.TakeExpeditionBoxRewardRequest other) { public Builder mergeFrom(com.ljsd.jieling.protocols.Expedition.TakeExpeditionBoxRewardRequest other) {
if (other == com.ljsd.jieling.protocols.Expedition.TakeExpeditionBoxRewardRequest.getDefaultInstance()) return this; if (other == com.ljsd.jieling.protocols.Expedition.TakeExpeditionBoxRewardRequest.getDefaultInstance()) return this;
if (other.hasLay()) { if (other.hasLaycfg()) {
setLay(other.getLay()); setLaycfg(other.getLaycfg());
} }
this.mergeUnknownFields(other.getUnknownFields()); this.mergeUnknownFields(other.getUnknownFields());
return this; return this;
@ -2524,51 +2643,51 @@ public final class Expedition {
} }
private int bitField0_; private int bitField0_;
// optional int32 lay = 1; // optional int32 laycfg = 1;
private int lay_ ; private int laycfg_ ;
/** /**
* <code>optional int32 lay = 1;</code> * <code>optional int32 laycfg = 1;</code>
* *
* <pre> * <pre>
* *id
* </pre> * </pre>
*/ */
public boolean hasLay() { public boolean hasLaycfg() {
return ((bitField0_ & 0x00000001) == 0x00000001); return ((bitField0_ & 0x00000001) == 0x00000001);
} }
/** /**
* <code>optional int32 lay = 1;</code> * <code>optional int32 laycfg = 1;</code>
* *
* <pre> * <pre>
* *id
* </pre> * </pre>
*/ */
public int getLay() { public int getLaycfg() {
return lay_; return laycfg_;
} }
/** /**
* <code>optional int32 lay = 1;</code> * <code>optional int32 laycfg = 1;</code>
* *
* <pre> * <pre>
* *id
* </pre> * </pre>
*/ */
public Builder setLay(int value) { public Builder setLaycfg(int value) {
bitField0_ |= 0x00000001; bitField0_ |= 0x00000001;
lay_ = value; laycfg_ = value;
onChanged(); onChanged();
return this; return this;
} }
/** /**
* <code>optional int32 lay = 1;</code> * <code>optional int32 laycfg = 1;</code>
* *
* <pre> * <pre>
* *id
* </pre> * </pre>
*/ */
public Builder clearLay() { public Builder clearLaycfg() {
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000001);
lay_ = 0; laycfg_ = 0;
onChanged(); onChanged();
return this; return this;
} }
@ -2600,6 +2719,32 @@ public final class Expedition {
* <code>optional .com.ljsd.jieling.protocols.Drop drop = 1;</code> * <code>optional .com.ljsd.jieling.protocols.Drop drop = 1;</code>
*/ */
com.ljsd.jieling.protocols.CommonProto.DropOrBuilder getDropOrBuilder(); 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} * Protobuf type {@code com.ljsd.jieling.protocols.TakeExpeditionBoxRewardResponse}
@ -2665,6 +2810,27 @@ public final class Expedition {
bitField0_ |= 0x00000001; bitField0_ |= 0x00000001;
break; 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) { } catch (com.google.protobuf.InvalidProtocolBufferException e) {
@ -2673,6 +2839,9 @@ public final class Expedition {
throw new com.google.protobuf.InvalidProtocolBufferException( throw new com.google.protobuf.InvalidProtocolBufferException(
e.getMessage()).setUnfinishedMessage(this); e.getMessage()).setUnfinishedMessage(this);
} finally { } finally {
if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
leve_ = java.util.Collections.unmodifiableList(leve_);
}
this.unknownFields = unknownFields.build(); this.unknownFields = unknownFields.build();
makeExtensionsImmutable(); makeExtensionsImmutable();
} }
@ -2727,8 +2896,44 @@ public final class Expedition {
return drop_; 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() { private void initFields() {
drop_ = com.ljsd.jieling.protocols.CommonProto.Drop.getDefaultInstance(); drop_ = com.ljsd.jieling.protocols.CommonProto.Drop.getDefaultInstance();
leve_ = java.util.Collections.emptyList();
} }
private byte memoizedIsInitialized = -1; private byte memoizedIsInitialized = -1;
public final boolean isInitialized() { public final boolean isInitialized() {
@ -2745,6 +2950,9 @@ public final class Expedition {
if (((bitField0_ & 0x00000001) == 0x00000001)) { if (((bitField0_ & 0x00000001) == 0x00000001)) {
output.writeMessage(1, drop_); output.writeMessage(1, drop_);
} }
for (int i = 0; i < leve_.size(); i++) {
output.writeInt32(2, leve_.get(i));
}
getUnknownFields().writeTo(output); getUnknownFields().writeTo(output);
} }
@ -2758,6 +2966,15 @@ public final class Expedition {
size += com.google.protobuf.CodedOutputStream size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, drop_); .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(); size += getUnknownFields().getSerializedSize();
memoizedSerializedSize = size; memoizedSerializedSize = size;
return size; return size;
@ -2881,6 +3098,8 @@ public final class Expedition {
dropBuilder_.clear(); dropBuilder_.clear();
} }
bitField0_ = (bitField0_ & ~0x00000001); bitField0_ = (bitField0_ & ~0x00000001);
leve_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
return this; return this;
} }
@ -2917,6 +3136,11 @@ public final class Expedition {
} else { } else {
result.drop_ = dropBuilder_.build(); result.drop_ = dropBuilder_.build();
} }
if (((bitField0_ & 0x00000002) == 0x00000002)) {
leve_ = java.util.Collections.unmodifiableList(leve_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.leve_ = leve_;
result.bitField0_ = to_bitField0_; result.bitField0_ = to_bitField0_;
onBuilt(); onBuilt();
return result; return result;
@ -2936,6 +3160,16 @@ public final class Expedition {
if (other.hasDrop()) { if (other.hasDrop()) {
mergeDrop(other.getDrop()); 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()); this.mergeUnknownFields(other.getUnknownFields());
return this; return this;
} }
@ -3080,6 +3314,100 @@ public final class Expedition {
return dropBuilder_; 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) // @@protoc_insertion_point(builder_scope:com.ljsd.jieling.protocols.TakeExpeditionBoxRewardResponse)
} }
@ -13066,49 +13394,50 @@ public final class Expedition {
static { static {
java.lang.String[] descriptorData = { java.lang.String[] descriptorData = {
"\n\020Expedition.proto\022\032com.ljsd.jieling.pro" + "\n\020Expedition.proto\022\032com.ljsd.jieling.pro" +
"tocols\032\021CommonProto.proto\"\026\n\024GetExpediti" + "tocols\032\021CommonProto.proto\"$\n\024GetExpediti" +
"onRequest\"\355\001\n\025GetExpeditionResponse\022@\n\010n" + "onRequest\022\014\n\004leve\030\001 \001(\005\"\355\001\n\025GetExpeditio" +
"odeInfo\030\001 \003(\0132..com.ljsd.jieling.protoco" + "nResponse\022@\n\010nodeInfo\030\001 \003(\0132..com.ljsd.j" +
"ls.ExpeditionNodeInfo\022F\n\010heroInfo\030\002 \003(\0132" + "ieling.protocols.ExpeditionNodeInfo\022F\n\010h" +
"4.com.ljsd.jieling.protocols.ExpeditionS" + "eroInfo\030\002 \003(\01324.com.ljsd.jieling.protoco" +
"impleHeroInfo\022\013\n\003lay\030\003 \003(\005\022=\n\010equipIds\030\004" + "ls.ExpeditionSimpleHeroInfo\022\013\n\003lay\030\003 \003(\005" +
" \003(\0132+.com.ljsd.jieling.protocols.Expedi" + "\022=\n\010equipIds\030\004 \003(\0132+.com.ljsd.jieling.pr" +
"tionEquip\"-\n\036TakeExpeditionBoxRewardRequ" + "otocols.ExpeditionEquip\"0\n\036TakeExpeditio" +
"est\022\013\n\003lay\030\001 \001(\005\"Q\n\037TakeExpeditionBoxRew", "nBoxRewardRequest\022\016\n\006laycfg\030\001 \001(\005\"_\n\037Tak",
"ardResponse\022.\n\004drop\030\001 \001(\0132 .com.ljsd.jie" + "eExpeditionBoxRewardResponse\022.\n\004drop\030\001 \001" +
"ling.protocols.Drop\"=\n\033ReliveExpeditionH" + "(\0132 .com.ljsd.jieling.protocols.Drop\022\014\n\004" +
"eroRequest\022\016\n\006heroId\030\001 \001(\t\022\016\n\006nodeId\030\002 \001" + "leve\030\002 \003(\005\"=\n\033ReliveExpeditionHeroReques" +
"(\005\"f\n\034ReliveExpeditionHeroResponse\022F\n\010he" + "t\022\016\n\006heroId\030\001 \001(\t\022\016\n\006nodeId\030\002 \001(\005\"f\n\034Rel" +
"roInfo\030\001 \001(\01324.com.ljsd.jieling.protocol" + "iveExpeditionHeroResponse\022F\n\010heroInfo\030\001 " +
"s.ExpeditionSimpleHeroInfo\".\n\034ReCoverExp" + "\001(\01324.com.ljsd.jieling.protocols.Expedit" +
"editionHeroRequest\022\016\n\006nodeId\030\001 \001(\005\"g\n\035Re" + "ionSimpleHeroInfo\".\n\034ReCoverExpeditionHe" +
"CoverExpeditionHeroResponse\022F\n\010heroInfo\030" + "roRequest\022\016\n\006nodeId\030\001 \001(\005\"g\n\035ReCoverExpe" +
"\001 \003(\01324.com.ljsd.jieling.protocols.Exped" + "ditionHeroResponse\022F\n\010heroInfo\030\001 \003(\01324.c" +
"itionSimpleHeroInfo\">\n\034StartExpeditionBa", "om.ljsd.jieling.protocols.ExpeditionSimp",
"ttleRequest\022\016\n\006nodeId\030\001 \001(\005\022\016\n\006teamId\030\002 " + "leHeroInfo\">\n\034StartExpeditionBattleReque" +
"\001(\005\"Y\n\035StartExpeditionBattleResponse\0228\n\t" + "st\022\016\n\006nodeId\030\001 \001(\005\022\016\n\006teamId\030\002 \001(\005\"Y\n\035St" +
"fightData\030\001 \001(\0132%.com.ljsd.jieling.proto" + "artExpeditionBattleResponse\0228\n\tfightData" +
"cols.FightData\"<\n\032EndExpeditionBattleReq" + "\030\001 \001(\0132%.com.ljsd.jieling.protocols.Figh" +
"uest\022\016\n\006nodeId\030\001 \001(\005\022\016\n\006frames\030\002 \001(\t\"]\n\033" + "tData\"<\n\032EndExpeditionBattleRequest\022\016\n\006n" +
"EndExpeditionBattleResponse\022\016\n\006result\030\001 " + "odeId\030\001 \001(\005\022\016\n\006frames\030\002 \001(\t\"]\n\033EndExpedi" +
"\001(\005\022.\n\004drop\030\002 \001(\0132 .com.ljsd.jieling.pro" + "tionBattleResponse\022\016\n\006result\030\001 \001(\005\022.\n\004dr" +
"tocols.Drop\"4\n\024TakeHolyEquipRequest\022\016\n\006n" + "op\030\002 \001(\0132 .com.ljsd.jieling.protocols.Dr" +
"odeId\030\001 \001(\005\022\014\n\004type\030\002 \001(\005\"(\n\025TakeHolyEqu" + "op\"4\n\024TakeHolyEquipRequest\022\016\n\006nodeId\030\001 \001" +
"ipResponse\022\017\n\007equipId\030\001 \001(\t\"Z\n\031Expeditio", "(\005\022\014\n\004type\030\002 \001(\005\"(\n\025TakeHolyEquipRespons",
"nEquipIndication\022=\n\010equipIds\030\001 \003(\0132+.com" + "e\022\017\n\007equipId\030\001 \001(\t\"Z\n\031ExpeditionEquipInd" +
".ljsd.jieling.protocols.ExpeditionEquip\"" + "ication\022=\n\010equipIds\030\001 \003(\0132+.com.ljsd.jie" +
"\250\001\n\034ExpeditionNodeInfoIndication\022@\n\010node" + "ling.protocols.ExpeditionEquip\"\250\001\n\034Exped" +
"Info\030\001 \003(\0132..com.ljsd.jieling.protocols." + "itionNodeInfoIndication\022@\n\010nodeInfo\030\001 \003(" +
"ExpeditionNodeInfo\022F\n\010heroInfo\030\002 \003(\01324.c" + "\0132..com.ljsd.jieling.protocols.Expeditio" +
"om.ljsd.jieling.protocols.ExpeditionSimp" + "nNodeInfo\022F\n\010heroInfo\030\002 \003(\01324.com.ljsd.j" +
"leHeroInfo\"+\n\035ExpeditionTakeTreasureRequ" + "ieling.protocols.ExpeditionSimpleHeroInf" +
"est\022\n\n\002id\030\001 \001(\005\"P\n\036ExpeditionTakeTreasur" + "o\"+\n\035ExpeditionTakeTreasureRequest\022\n\n\002id" +
"eResponse\022.\n\004drop\030\001 \001(\0132 .com.ljsd.jieli" + "\030\001 \001(\005\"P\n\036ExpeditionTakeTreasureResponse" +
"ng.protocols.Drop\"0\n\023TreasureRewardState", "\022.\n\004drop\030\001 \001(\0132 .com.ljsd.jieling.protoc",
"\022\n\n\002id\030\001 \001(\005\022\r\n\005state\030\002 \001(\005\"u\n\026TreasureS" + "ols.Drop\"0\n\023TreasureRewardState\022\n\n\002id\030\001 " +
"tateIndicaion\022\r\n\005score\030\001 \001(\005\022L\n\023treasure" + "\001(\005\022\r\n\005state\030\002 \001(\005\"u\n\026TreasureStateIndic" +
"RewardState\030\002 \003(\0132/.com.ljsd.jieling.pro" + "aion\022\r\n\005score\030\001 \001(\005\022L\n\023treasureRewardSta" +
"tocols.TreasureRewardStateB\002H\001" "te\030\002 \003(\0132/.com.ljsd.jieling.protocols.Tr" +
"easureRewardStateB\002H\001"
}; };
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() { new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
@ -13120,7 +13449,7 @@ public final class Expedition {
internal_static_com_ljsd_jieling_protocols_GetExpeditionRequest_fieldAccessorTable = new internal_static_com_ljsd_jieling_protocols_GetExpeditionRequest_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable( com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_com_ljsd_jieling_protocols_GetExpeditionRequest_descriptor, 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 = internal_static_com_ljsd_jieling_protocols_GetExpeditionResponse_descriptor =
getDescriptor().getMessageTypes().get(1); getDescriptor().getMessageTypes().get(1);
internal_static_com_ljsd_jieling_protocols_GetExpeditionResponse_fieldAccessorTable = new 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 internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardRequest_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable( com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardRequest_descriptor, 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 = internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardResponse_descriptor =
getDescriptor().getMessageTypes().get(3); getDescriptor().getMessageTypes().get(3);
internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardResponse_fieldAccessorTable = new internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardResponse_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable( com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_com_ljsd_jieling_protocols_TakeExpeditionBoxRewardResponse_descriptor, 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 = internal_static_com_ljsd_jieling_protocols_ReliveExpeditionHeroRequest_descriptor =
getDescriptor().getMessageTypes().get(4); getDescriptor().getMessageTypes().get(4);
internal_static_com_ljsd_jieling_protocols_ReliveExpeditionHeroRequest_fieldAccessorTable = new internal_static_com_ljsd_jieling_protocols_ReliveExpeditionHeroRequest_fieldAccessorTable = new

View File

@ -32,7 +32,9 @@ public class CarDelayFunction implements FunctionManager {
Set<String> guildSet = RedisUtil.getInstence().getZset(guildKey, 0, -1); Set<String> guildSet = RedisUtil.getInstence().getZset(guildKey, 0, -1);
guildSet.forEach(guildId->{ guildSet.forEach(guildId->{
GuildInfo guildInfo = GuilidManager.guildInfoMap.get(Integer.parseInt(guildId)); GuildInfo guildInfo = GuilidManager.guildInfoMap.get(Integer.parseInt(guildId));
guildInfo.clearCarFightSb(); if(guildInfo != null){
guildInfo.clearCarFightSb();
}
}); });
MongoUtil.getLjsdMongoTemplate().lastUpdate(); MongoUtil.getLjsdMongoTemplate().lastUpdate();
RedisUtil.getInstence().del(delKeys.toArray(new String[0])); RedisUtil.getInstence().del(delKeys.toArray(new String[0]));
@ -41,8 +43,8 @@ public class CarDelayFunction implements FunctionManager {
@Override @Override
public void closeAction() throws Exception { public void closeAction() throws Exception {
Map<Integer, TreeMap<Integer, String>> rewardByTypeAndRankMap = SWorldBossRewardConfig.rewardByTypeAndRankMap; Map<Integer, TreeMap<Integer, String>> rewardByTypeAndRankMap = SWorldBossRewardConfig.rewardByTypeAndRankMap;
TreeMap<Integer, String> personRewardConfigTreeMap = rewardByTypeAndRankMap.get(1); TreeMap<Integer, String> personRewardConfigTreeMap = rewardByTypeAndRankMap.get(2);
TreeMap<Integer, String> guildRewardConfigTreeMap = rewardByTypeAndRankMap.get(2); TreeMap<Integer, String> guildRewardConfigTreeMap = rewardByTypeAndRankMap.get(1);
Set<ZSetOperations.TypedTuple<String>> personRangeWithScores = RedisUtil.getInstence().getZsetreverseRangeWithScores(RedisKey.CAR_DEALY_RANK, "", 0, -1); Set<ZSetOperations.TypedTuple<String>> personRangeWithScores = RedisUtil.getInstence().getZsetreverseRangeWithScores(RedisKey.CAR_DEALY_RANK, "", 0, -1);
int rank=0; int rank=0;
String personTitle = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_personreward_title"); String personTitle = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_personreward_title");
@ -63,12 +65,17 @@ public class CarDelayFunction implements FunctionManager {
MongoUtil.getLjsdMongoTemplate().lastUpdate(); MongoUtil.getLjsdMongoTemplate().lastUpdate();
String guildTitle = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_familyreward_title"); String guildTitle = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_familyreward_title");
Set<ZSetOperations.TypedTuple<String>> guildRangeWithScores = RedisUtil.getInstence().getZsetreverseRangeWithScores(RedisKey.CAR_DEALY_GUILD_RANK, "", 0, -1); Set<ZSetOperations.TypedTuple<String>> guildRangeWithScores = RedisUtil.getInstence().getZsetreverseRangeWithScores(RedisKey.CAR_DEALY_GUILD_RANK, "", 0, -1);
rank=0;
for(ZSetOperations.TypedTuple<String> item : guildRangeWithScores){ for(ZSetOperations.TypedTuple<String> item : guildRangeWithScores){
rank++;
String value = item.getValue(); String value = item.getValue();
int guildId = Integer.parseInt(value); int guildId = Integer.parseInt(value);
String rewardByRank = guildRewardConfigTreeMap.floorEntry(rank).getValue(); String rewardByRank = guildRewardConfigTreeMap.floorEntry(rank).getValue();
GuildInfo guildInfo = GuilidManager.guildInfoMap.get(guildId); GuildInfo guildInfo = GuilidManager.guildInfoMap.get(guildId);
if(guildInfo==null){
continue;
}
rank++;
Collection<Set<Integer>> values = guildInfo.getMembers().values(); Collection<Set<Integer>> values = guildInfo.getMembers().values();
String guildContent = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_familyreward_txt",new Object[]{rank}); String guildContent = SErrorCodeEerverConfig.getI18NMessage("family_fight_rank_familyreward_txt",new Object[]{rank});
for(Set<Integer> uids : values){ for(Set<Integer> uids : values){

View File

@ -3,7 +3,6 @@ package com.ljsd.jieling.globals;
public interface Global { public interface Global {
int EXECUTION = 1;//行动力id int EXECUTION = 1;//行动力id
int STAMINA = 2; // 体力id int STAMINA = 2; // 体力id
int DROP = 53;//水滴
int HEROSTORY_TICKET = 28; //精英入场券 int HEROSTORY_TICKET = 28; //精英入场券
int GENERALSTORY_TICKET = 27; //普通入场券 int GENERALSTORY_TICKET = 27; //普通入场券
int INVASIONBOSS_TICKET = 44; //外敌挑战券 int INVASIONBOSS_TICKET = 44; //外敌挑战券

View File

@ -10,6 +10,7 @@ import com.ljsd.jieling.logic.dao.root.User;
import com.ljsd.jieling.logic.expedition.ExpeditionLogic; import com.ljsd.jieling.logic.expedition.ExpeditionLogic;
import com.ljsd.jieling.logic.fight.DefFightSnapData; import com.ljsd.jieling.logic.fight.DefFightSnapData;
import com.ljsd.jieling.logic.fight.FightUtil; 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.HeroAttributeEnum;
import com.ljsd.jieling.logic.hero.HeroLogic; import com.ljsd.jieling.logic.hero.HeroLogic;
import com.ljsd.jieling.network.session.ISession; import com.ljsd.jieling.network.session.ISession;
@ -157,6 +158,7 @@ public class StartExpeditionBattleRequest extends BaseHandler<Expedition.StartEx
.addAllFightUnitList(heroFightInfos) .addAllFightUnitList(heroFightInfos)
.setTeamSkillList(HeroLogic.getInstance().getPokenmonSkills(user,teamId)) .setTeamSkillList(HeroLogic.getInstance().getPokenmonSkills(user,teamId))
.setTeamPassiveList(pokenmonPassiveSkills+holySkill) .setTeamPassiveList(pokenmonPassiveSkills+holySkill)
.setSpecialPassive(SpecialForTeamBuildEnum.toParm(teamId,user))
.build(); .build();
} }
} }

View File

@ -28,6 +28,7 @@ import config.SErrorCodeEerverConfig;
import config.SWorldBossConfig; import config.SWorldBossConfig;
import config.SWorldBossSetting; import config.SWorldBossSetting;
import manager.STableManager; import manager.STableManager;
import util.TimeUtils;
import java.util.List; import java.util.List;
@ -76,6 +77,7 @@ public class FastChallengeHandler extends BaseHandler<FightInfoProto.FastFightCh
int challeageId = proto.getChalleageId(); int challeageId = proto.getChalleageId();
int battleRound = sWorldBossSetting.getBattleRound(); int battleRound = sWorldBossSetting.getBattleRound();
CommonProto.FightData fightData= null; CommonProto.FightData fightData= null;
boolean isNew = guildInfo.addCarFightSb(uid);
switch (type){ switch (type){
case 1:{ case 1:{
int monsterId = STableManager.getConfig(SWorldBossConfig.class).get(GuildFightLogic.carDelayProgressIndication.getBossIndexId()).getMonsterId(); 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]; hurt = fightResult.getCheckResult()[1];
fightData = fightResult.getFightData(); fightData = fightResult.getFightData();
gainScore = (int) (hurt*(sWorldBossSetting.getScorePercent()/10000F)); 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_RANK.getType()).incrementRankScore(uid,"",gainScore);
RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(guildInfo.getId(),"",gainScore,isNew?1:0); 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 = ""; String challengeContent = "";
PlayerManager playerInfoManager = UserManager.getUser(challeageId).getPlayerInfoManager(); PlayerManager playerInfoManager = UserManager.getUser(challeageId).getPlayerInfoManager();
String challengeName = playerInfoManager.getNickName(); String challengeName = playerInfoManager.getNickName();
if(fight == 1){ if(fight == 1){
int challenegScore = RedisUtil.getInstence().getZSetScore(RankEnum.CAR_DEALY_RANK.getRedisKey(), "", String.valueOf(challeageId)).intValue(); int challenegScore = RedisUtil.getInstence().getZSetScore(RankEnum.CAR_DEALY_RANK.getRedisKey(), "", String.valueOf(challeageId)).intValue();
if(challenegScore !=-1){ if(challenegScore !=-1){
gainScore = (int) (challenegScore*(sWorldBossSetting.getGrabPercent()/10000F)); gainScore = (int) (challenegScore*(sWorldBossSetting.getGrabPercent()/10000F));
RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(uid,"",gainScore); if(gainScore!=0){
RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(challeageId,"",-gainScore); RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(uid,"",gainScore);
RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(guildInfo.getId(),"",gainScore,0); RankEnum.toRank(RankEnum.CAR_DEALY_RANK.getType()).incrementRankScore(challeageId,"",-gainScore);
int chanllengeGuild = playerInfoManager.getGuildId(); RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(guildInfo.getId(),"",gainScore,isNew?1:0);
if(chanllengeGuild!=0){ int chanllengeGuild = playerInfoManager.getGuildId();
RankEnum.toRank(RankEnum.CAR_DEALY_GUILD_RANK.getType()).incrementRankScore(chanllengeGuild,"",-gainScore,0); 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}); content = SErrorCodeEerverConfig.getI18NMessage("worldboss_battle_win",new Object[]{challengeName,gainScore});
challengeContent = SErrorCodeEerverConfig.getI18NMessage("worldboss_grab_win",new Object[]{user.getPlayerInfoManager().getNickName(),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}); content = SErrorCodeEerverConfig.getI18NMessage("worldboss_battle_lose",new Object[]{challengeName,gainScore});
challengeContent = SErrorCodeEerverConfig.getI18NMessage("worldboss_grab_lose",new Object[]{user.getPlayerInfoManager().getNickName(),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 key = RedisUtil.getInstence().getKey(RedisKey.CAR_CHALLENGE_RECORD, String.valueOf(uid));
String challenegeKey = RedisUtil.getInstence().getKey(RedisKey.CAR_CHALLENGE_RECORD, String.valueOf(challeageId)); 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(key,content + "|" + challeageId,(int)(System.currentTimeMillis()/1000));
RedisUtil.getInstence().zsetAddOne(challenegeKey,challengeContent + "|" + uid,(int)(System.currentTimeMillis()/1000)); RedisUtil.getInstence().zsetAddOne(challenegeKey,challengeContent + "|" + uid,(int)(System.currentTimeMillis()/1000));
guildInfo.addCarFightSb(uid);
}break; }break;
default: default:
throw new ErrorCodeException(ErrorCode.SERVER_DEFINE); throw new ErrorCodeException(ErrorCode.SERVER_DEFINE);
} }
user.getGuildMyInfo().setCarPlayTime(TimeUtils.nowInt());
FightInfoProto.FastFightChallengeResponse build = FightInfoProto.FastFightChallengeResponse.newBuilder().setHurt(hurt).setScore(gainScore).setFightData(fightData).build(); 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); MessageUtil.sendMessage(iSession,1, MessageTypeProto.MessageType.FAST_FIGHT_CHALLENGE_RESPONSE_VALUE,build,true);
} }

View File

@ -2262,22 +2262,12 @@ public class MapLogic {
LOGGER.info("endFight() uid=>{} fightId=>{} SLevelDifficultyConfig == null", uid, fightId); LOGGER.info("endFight() uid=>{} fightId=>{} SLevelDifficultyConfig == null", uid, fightId);
throw new ErrorCodeException(ErrorCode.SERVER_SELF_DEFINE); 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); List<TeamPosHeroInfo> teamPosHeroInfos = user.getTeamPosManager().getTeamPosForHero().get(teamId);
if (teamPosHeroInfos == null || teamPosHeroInfos.size() == 0) { if (teamPosHeroInfos == null || teamPosHeroInfos.size() == 0) {
LOGGER.info("startLevelDifficultyFight==> uid={},fightId={},teamId={}", uid, fightId, teamId); LOGGER.info("startLevelDifficultyFight==> uid={},fightId={},teamId={}", uid, fightId, teamId);
throw new ErrorCodeException(ErrorCode.newDefineCode("阵容有误!!")); throw new ErrorCodeException(ErrorCode.newDefineCode("阵容有误!!"));
} }
ItemUtil.itemCost(user,cost, BIReason.MONSTERATTACK_CONSUME, fightId);
KtEventUtils.onKtEvent(user, ParamEventBean.UserGameType, KTGameType.CHALLENGE_MONSTERATTACK.getIndex(), fightId); KtEventUtils.onKtEvent(user, ParamEventBean.UserGameType, KTGameType.CHALLENGE_MONSTERATTACK.getIndex(), fightId);
user.getTeamPosManager().setCurTeamPosId(teamId); user.getTeamPosManager().setCurTeamPosId(teamId);
String fightInfo = fightId + "#" + teamId; String fightInfo = fightId + "#" + teamId;
@ -2334,10 +2324,6 @@ public class MapLogic {
// String rankKey = RedisKey.getKey(RedisKey.MONSTER_ATTACK_RANK,"", false); // String rankKey = RedisKey.getKey(RedisKey.MONSTER_ATTACK_RANK,"", false);
// RedisUtil.getInstence().zsetAddOneOffsetByTime(rankKey, String.valueOf(user.getId()), checkFightId); // RedisUtil.getInstence().zsetAddOneOffsetByTime(rankKey, String.valueOf(user.getId()), checkFightId);
RankContext.getRankEnum(RankEnum.MONSTER_ATTACK_RANK.getType()).addRank(uid,"",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); CommonProto.Drop.Builder drop = ItemUtil.drop(user, sFloodConfig.getReward(), BIReason.MONSTERATTACK_REWARD);
FightInfoProto.FightEndResponse.Builder fightEndResponse = FightInfoProto.FightEndResponse.newBuilder(); FightInfoProto.FightEndResponse.Builder fightEndResponse = FightInfoProto.FightEndResponse.newBuilder();
fightEndResponse.setEnventDrop(drop); fightEndResponse.setEnventDrop(drop);

View File

@ -2,6 +2,7 @@ package com.ljsd.jieling.handler.map.behavior;
import com.googlecode.protobuf.format.JsonFormat; import com.googlecode.protobuf.format.JsonFormat;
import com.ljsd.fight.FightType; import com.ljsd.fight.FightType;
import com.ljsd.jieling.logic.fight.specialparm.SpecialForTeamBuildEnum;
import com.ljsd.jieling.logic.hero.HeroAttributeEnum; import com.ljsd.jieling.logic.hero.HeroAttributeEnum;
import com.ljsd.jieling.util.CBean2Proto; import com.ljsd.jieling.util.CBean2Proto;
import config.MapPointConfig; import config.MapPointConfig;
@ -282,6 +283,7 @@ public class BehaviorUtil {
.addAllFightUnitList(heroFightInfos) .addAllFightUnitList(heroFightInfos)
.setTeamSkillList(HeroLogic.getInstance().getPokenmonSkills(user,teamId)) .setTeamSkillList(HeroLogic.getInstance().getPokenmonSkills(user,teamId))
.setTeamPassiveList(HeroLogic.getInstance().getPokenmonPassiveSkills(user,teamId)) .setTeamPassiveList(HeroLogic.getInstance().getPokenmonPassiveSkills(user,teamId))
.setSpecialPassive(SpecialForTeamBuildEnum.toParm(teamId,user))
.build(); .build();
} }

View File

@ -72,15 +72,6 @@ public class QuickStartMonsterFighter extends BaseHandler<FightInfoProto.QuickSt
LOGGER.info("endFight() uid=>{} fightId=>{} SLevelDifficultyConfig == null", uid, fightId); LOGGER.info("endFight() uid=>{} fightId=>{} SLevelDifficultyConfig == null", uid, fightId);
throw new ErrorCodeException(ErrorCode.CFG_NULL); 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); List<TeamPosHeroInfo> teamPosHeroInfos = user.getTeamPosManager().getTeamPosForHero().get(teamId);
if (teamPosHeroInfos == null || teamPosHeroInfos.size() == 0) { if (teamPosHeroInfos == null || teamPosHeroInfos.size() == 0) {
LOGGER.info("startLevelDifficultyFight==> uid={},fightId={},teamId={}", uid, fightId, teamId); LOGGER.info("startLevelDifficultyFight==> uid={},fightId={},teamId={}", uid, fightId, teamId);
@ -108,7 +99,6 @@ public class QuickStartMonsterFighter extends BaseHandler<FightInfoProto.QuickSt
.build(); .build();
if (resultCode == 0) { if (resultCode == 0) {
ItemUtil.itemCost(user,cost, BIReason.MONSTERATTACK_CONSUME, fightId);
CommonProto.Drop.Builder dropBuilder = CommonProto.Drop.newBuilder(); CommonProto.Drop.Builder dropBuilder = CommonProto.Drop.newBuilder();
FightInfoProto.QuickStartMonsterFightResponse builder = FightInfoProto.QuickStartMonsterFightResponse.newBuilder() FightInfoProto.QuickStartMonsterFightResponse builder = FightInfoProto.QuickStartMonsterFightResponse.newBuilder()
.setResult(resultCode) .setResult(resultCode)

View File

@ -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); List<SGlobalSystemConfig> sGlobalSystemConfigs = STableManager.getFigureConfig(CommonStaticConfig.class).getsGlobalSystemConfigMapByTypeAndConditionMap().get(1).get(fightId);
if(sGlobalSystemConfigs == null){ if(sGlobalSystemConfigs == null){

View File

@ -1,5 +1,6 @@
package com.ljsd.jieling.logic.activity; package com.ljsd.jieling.logic.activity;
import com.ljsd.jieling.jbean.ActivityMission;
import com.ljsd.jieling.jbean.ActivityProgressInfo; import com.ljsd.jieling.jbean.ActivityProgressInfo;
import com.ljsd.jieling.logic.dao.UserManager; import com.ljsd.jieling.logic.dao.UserManager;
import com.ljsd.jieling.logic.dao.root.User; import com.ljsd.jieling.logic.dao.root.User;
@ -42,4 +43,9 @@ class GrowthFundActivity extends AbstractActivity {
SGlobalActivity sGlobalActivity = SGlobalActivity.getsGlobalActivityMap().get(id); SGlobalActivity sGlobalActivity = SGlobalActivity.getsGlobalActivityMap().get(id);
user.getPlayerInfoManager().getRechargeInfo().updateBuyGoodsTimes(sGlobalActivity.getCanBuyRechargeId(),0); user.getPlayerInfoManager().getRechargeInfo().updateBuyGoodsTimes(sGlobalActivity.getCanBuyRechargeId(),0);
} }
@Override
void updateProgress(ActivityMission activityMission, int count) {
activityMission.setV(count);
}
} }

View File

@ -44,16 +44,13 @@ public class TreasureActivity extends AbstractActivity {
if(user.getPlayerInfoManager().getHadBuyTreasure() == 1){ if(user.getPlayerInfoManager().getHadBuyTreasure() == 1){
LOGGER.info("戒灵秘宝初始化...reset buy"); LOGGER.info("戒灵秘宝初始化...reset buy");
user.getPlayerInfoManager().setHadBuyTreasure(0); user.getPlayerInfoManager().setHadBuyTreasure(0);
Map<Integer, Integer> buyGoodsTimes = user.getPlayerInfoManager().getRechargeInfo().getBuyGoodsTimes();
int id=0; int id=0;
for(SRechargeCommodityConfig sRechargeCommodityConfig : SRechargeCommodityConfig.rechargeCommodityConfigMap.values()){ for(SRechargeCommodityConfig sRechargeCommodityConfig : SRechargeCommodityConfig.rechargeCommodityConfigMap.values()){
if(sRechargeCommodityConfig.getType() == GiftGoodsType.SUN_LONG){ if(sRechargeCommodityConfig.getType() == GiftGoodsType.SUN_LONG){
id=sRechargeCommodityConfig.getId(); id=sRechargeCommodityConfig.getId();
} }
} }
buyGoodsTimes.put(id,0); user.getPlayerInfoManager().getRechargeInfo().updateBuyGoodsTimes(id,0);
user.getPlayerInfoManager().getRechargeInfo().setBuyGoodsTimes(buyGoodsTimes);
user.getPlayerInfoManager().getRechargeInfo().clearCacheSendId();
} }
SGlobalActivity sGlobalActivity = SGlobalActivity.getsGlobalActivityMap().get(id); SGlobalActivity sGlobalActivity = SGlobalActivity.getsGlobalActivityMap().get(id);

View File

@ -62,9 +62,15 @@ public class UserLevelEventHandler implements IEventHandler,IPrivilegeChange{
activityMission.setActivityState(ActivityType.OPEN_STATE); activityMission.setActivityState(ActivityType.OPEN_STATE);
ActivityLogic.getInstance().sendActivityInfo(user,sGlobalActivity.getId()); ActivityLogic.getInstance().sendActivityInfo(user,sGlobalActivity.getId());
Poster.getPoster().dispatchEvent(new ActivityStateChangeEvent(user.getId(),sGlobalActivity.getId(),ActivityType.OPEN_STATE)); 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){ if(sGlobalSystemConfigs == null){
return; return;
} }

View File

@ -41,6 +41,8 @@ public class ActivityStateChangeHandler implements IEventHandler {
if(sGlobalActivity.getCanBuyRechargeId()!=0){ if(sGlobalActivity.getCanBuyRechargeId()!=0){
user.getPlayerInfoManager().getRechargeInfo().putDyGoodsCanBuyTimes(sGlobalActivity.getCanBuyRechargeId(),1); user.getPlayerInfoManager().getRechargeInfo().putDyGoodsCanBuyTimes(sGlobalActivity.getCanBuyRechargeId(),1);
BuyGoodsLogic.sendGiftGooodsIndication(uid); 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){ }else if(state == ActivityType.CLOSE_STATE){
List<SGlobalActivity> sGlobalActivities = SGlobalActivity.sGlobalActivityMapByOpenRules.getOrDefault(3, new ArrayList<>(0)); 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){ if(activityMissionWillOpen!=null && activityMissionWillOpen.getActivityState() == ActivityType.UNOPEN_STATE){
AbstractActivity abstractActivity = ActivityTypeEnum.getActicityType(s.getId()); AbstractActivity abstractActivity = ActivityTypeEnum.getActicityType(s.getId());
abstractActivity.setOpenState(user,ActivityType.OPEN_STATE); abstractActivity.setOpenState(user,ActivityType.OPEN_STATE);
Poster.getPoster().dispatchEvent(new ActivityStateChangeEvent(uid,s.getId(),ActivityType.OPEN_STATE)); ActivityLogic.getInstance().sendActivityInfo(user,s.getId());
} }
}); });
} }

View File

@ -35,6 +35,8 @@ public class GuildMyInfo extends MongoBase {
private boolean guildHelpReward;//公会奖励 private boolean guildHelpReward;//公会奖励
private long guildHelpSendTime;//公会求助信息时间 5分钟 private long guildHelpSendTime;//公会求助信息时间 5分钟
private int carPlayTime; //车迟上次玩的时间
public void clearOfLevelGuild(){ public void clearOfLevelGuild(){
@ -256,4 +258,13 @@ public class GuildMyInfo extends MongoBase {
this.guildHelpSendTime = guildHelpSendTime; this.guildHelpSendTime = guildHelpSendTime;
updateString("guildHelpSendTime",guildHelpSendTime); updateString("guildHelpSendTime",guildHelpSendTime);
} }
public void setCarPlayTime(int carPlayTime) {
this.carPlayTime = carPlayTime;
updateString("carPlayTime",carPlayTime);
}
public int getCarPlayTime() {
return carPlayTime;
}
} }

View File

@ -1,6 +1,7 @@
package com.ljsd.jieling.logic.dao; package com.ljsd.jieling.logic.dao;
import com.ljsd.jieling.db.mongo.MongoUtil; 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.db.redis.RedisUtil;
import com.ljsd.jieling.logic.dao.root.GuildApply; import com.ljsd.jieling.logic.dao.root.GuildApply;
import com.ljsd.jieling.logic.dao.root.GuildInfo; import com.ljsd.jieling.logic.dao.root.GuildInfo;
@ -101,18 +102,20 @@ public class GuilidManager {
needContinue=false; needContinue=false;
break; break;
} }
String carGuildDelay = RedisUtil.getInstence().getKey(RedisKey.CAR_DEALY_GUILD_RANK,"");
RedisUtil.getInstence().zsetRemoveOne(carGuildDelay,value);
GuildInfo guildInfo = guildInfoMap.get(Integer.parseInt(value)); GuildInfo guildInfo = guildInfoMap.get(Integer.parseInt(value));
if(guildInfo == null){ if(guildInfo == null){
RedisUtil.getInstence().zsetRemoveOne(key,value); RedisUtil.getInstence().zsetRemoveOne(key,value);
continue; continue;
} }
GuildLogic.releaseGuild(guildInfo); GuildLogic.releaseGuild(guildInfo);
RedisUtil.getInstence().zsetRemoveOne(key,value); RedisUtil.getInstence().zsetRemoveOne(key,value);
} }
round++; round++;
MongoUtil.getInstence().lastUpdate(); MongoUtil.getInstence().lastUpdate();
} }
} }
public static Collection<GuildInfo> recommandGuild(User user) { public static Collection<GuildInfo> recommandGuild(User user) {

View File

@ -133,6 +133,7 @@ public class RechargeInfo extends MongoBase{
public void updateBuyGoodsTimes(int goodsId,int times) { public void updateBuyGoodsTimes(int goodsId,int times) {
updateString("buyGoodsTimes."+goodsId,times); updateString("buyGoodsTimes."+goodsId,times);
this.buyGoodsTimes.put(goodsId,times); this.buyGoodsTimes.put(goodsId,times);
cacheSendedIds.remove(goodsId);
} }
public void updateGoodsTypeDuration(int goodsId,int durTime) { public void updateGoodsTypeDuration(int goodsId,int durTime) {
@ -220,6 +221,7 @@ public class RechargeInfo extends MongoBase{
public void putDyGoodsCanBuyTimes(Integer type,Integer value) { public void putDyGoodsCanBuyTimes(Integer type,Integer value) {
this.dyGoodsCanBuyTimes.put(type,value ); this.dyGoodsCanBuyTimes.put(type,value );
cacheSendedIds.remove(type);
updateString("dyGoodsCanBuyTimes",dyGoodsCanBuyTimes); updateString("dyGoodsCanBuyTimes",dyGoodsCanBuyTimes);
} }
public void removeDyGoodsCanBuyTimes(Integer type) { public void removeDyGoodsCanBuyTimes(Integer type) {

View File

@ -58,8 +58,8 @@ public class UserManager {
private static User registerUser(int uid,String openId,String channel,int pid,int gid) throws Exception { private static User registerUser(int uid,String openId,String channel,int pid,int gid) throws Exception {
User user = new User(uid); User user = new User(uid);
initPlayer(user,openId,channel,pid,gid);
UserManager.addUser(user); UserManager.addUser(user);
initPlayer(user,openId,channel,pid,gid);
MongoUtil.getInstence().getMyMongoTemplate().save(user); MongoUtil.getInstence().getMyMongoTemplate().save(user);
PlayerLogic.getInstance().sendTestWelfareMail(user,1,1); PlayerLogic.getInstance().sendTestWelfareMail(user,1,1);
return user; return user;

View File

@ -149,6 +149,7 @@ public class GuildLogic {
} }
} }
builder.setCarDelayProgressIndication(GuildFightLogic.carDelayProgressIndication); builder.setCarDelayProgressIndication(GuildFightLogic.carDelayProgressIndication);
builder.setCarPlayTime(user.getGuildMyInfo().getCarPlayTime());
MessageUtil.sendMessage(session,1,msgId,builder.build(),true); MessageUtil.sendMessage(session,1,msgId,builder.build(),true);
} }

View File

@ -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();
}
}

View File

@ -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);
}

View File

@ -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 "";
}
}

View File

@ -32,6 +32,9 @@ public class CarDealyGuildRank extends AbstractRank{
String value = data.getValue(); String value = data.getValue();
int guildId = Integer.parseInt(value); int guildId = Integer.parseInt(value);
GuildInfo guildInfo = GuilidManager.guildInfoMap.get(guildId); GuildInfo guildInfo = GuilidManager.guildInfoMap.get(guildId);
if(guildInfo == null){
return;
}
String familyName = guildInfo.getName(); String familyName = guildInfo.getName();
CommonProto.RankInfo.Builder everyRankInfo = CommonProto.RankInfo.newBuilder() CommonProto.RankInfo.Builder everyRankInfo = CommonProto.RankInfo.newBuilder()
.setRank(index) .setRank(index)

View File

@ -2,6 +2,7 @@ package com.ljsd.jieling.logic.store;
import com.ljsd.jieling.config.clazzStaticCfg.CommonStaticConfig; import com.ljsd.jieling.config.clazzStaticCfg.CommonStaticConfig;
import com.ljsd.jieling.core.GlobalsDef; import com.ljsd.jieling.core.GlobalsDef;
import com.ljsd.jieling.core.HandlerLogicThread;
import com.ljsd.jieling.core.VipPrivilegeType; import com.ljsd.jieling.core.VipPrivilegeType;
import com.ljsd.jieling.db.mongo.MongoUtil; import com.ljsd.jieling.db.mongo.MongoUtil;
import com.ljsd.jieling.exception.ErrorCode; 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); MessageUtil.sendIndicationMessage(session,1, MessageTypeProto.MessageType.REFRESH_RECHARGE_INDICATION_VALUE,builder.build(),true);
} }
buyGoodsTimes.put(goodsId,buyCount); rechargeInfo.updateBuyGoodsTimes(goodsId,buyCount);
rechargeInfo.setBuyGoodsTimes(buyGoodsTimes);
//直购礼包 //直购礼包
if(type == GiftGoodsType.DIRECTBAG){ if(type == GiftGoodsType.DIRECTBAG){
CommonProto.Drop.Builder drop = ItemUtil.drop(user, sRechargeCommodityConfig.getBaseReward(), BIReason.DIRECT_BUY); CommonProto.Drop.Builder drop = ItemUtil.drop(user, sRechargeCommodityConfig.getBaseReward(), BIReason.DIRECT_BUY);
@ -296,6 +296,7 @@ public class BuyGoodsLogic {
notifyPaySuccessFul(uid,goodsId,amount != -999); notifyPaySuccessFul(uid,goodsId,amount != -999);
Poster.getPoster().dispatchEvent(new NewWelfareEvent(user, NewWelfareTypeEnum.RECHARGE_BUY.getType(),goodsId)); Poster.getPoster().dispatchEvent(new NewWelfareEvent(user, NewWelfareTypeEnum.RECHARGE_BUY.getType(),goodsId));
MongoUtil.getLjsdMongoTemplate().lastUpdate(); MongoUtil.getLjsdMongoTemplate().lastUpdate();
sendGiftGooodsIndication(uid);
return resultRes; return resultRes;
} }
@ -406,7 +407,7 @@ public class BuyGoodsLogic {
if(limit!=0){ if(limit!=0){
if(buyTimes>=limit){ if(buyTimes>=limit){
boolean isNew = rechargeInfo.addNewSendId(goodsId); boolean isNew = rechargeInfo.addNewSendId(goodsId);
if(!isNew){ if(isNew){
needChange = true; needChange = true;
} }
continue; continue;
@ -531,7 +532,19 @@ public class BuyGoodsLogic {
while (iterator.hasNext()){ while (iterator.hasNext()){
ISession value = iterator.next(); ISession value = iterator.next();
if(value.getFiveReady() == 1){ 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);
} }
} }

View File

@ -176,6 +176,7 @@ public class FightDataUtil {
} }
playerData.set("teamSkill", getTeamSkill(heroTeam.getTeamSkillList())); playerData.set("teamSkill", getTeamSkill(heroTeam.getTeamSkillList()));
playerData.set("teamPassive", getTeamPassive(heroTeam.getTeamPassiveList())); playerData.set("teamPassive", getTeamPassive(heroTeam.getTeamPassiveList()));
playerData.set("outData",heroTeam.getSpecialPassive());
return playerData; return playerData;
} }