generated from root/miduo_server
增加google评论奖励模块
parent
a2e10f6272
commit
50467cf602
|
|
@ -7566,6 +7566,14 @@ public final class MessageTypeProto {
|
|||
* </pre>
|
||||
*/
|
||||
HERO_GET_INDICATION(1196, 922021),
|
||||
/**
|
||||
* <code>GET_GOOGLE_COMMENT_REWARD = 922022;</code>
|
||||
*
|
||||
* <pre>
|
||||
*领取谷歌评价奖励
|
||||
* </pre>
|
||||
*/
|
||||
GET_GOOGLE_COMMENT_REWARD(1197, 922022),
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -15121,6 +15129,14 @@ public final class MessageTypeProto {
|
|||
* </pre>
|
||||
*/
|
||||
public static final int HERO_GET_INDICATION_VALUE = 922021;
|
||||
/**
|
||||
* <code>GET_GOOGLE_COMMENT_REWARD = 922022;</code>
|
||||
*
|
||||
* <pre>
|
||||
*领取谷歌评价奖励
|
||||
* </pre>
|
||||
*/
|
||||
public static final int GET_GOOGLE_COMMENT_REWARD_VALUE = 922022;
|
||||
|
||||
|
||||
public final int getNumber() { return value; }
|
||||
|
|
@ -16324,6 +16340,7 @@ public final class MessageTypeProto {
|
|||
case 922018: return VOUCHER_PRICE_GOODS_RESPONSE;
|
||||
case 922020: return POWER_CENTER_INFO_INDICATION;
|
||||
case 922021: return HERO_GET_INDICATION;
|
||||
case 922022: return GET_GOOGLE_COMMENT_REWARD;
|
||||
default: return null;
|
||||
}
|
||||
}
|
||||
|
|
@ -16385,7 +16402,7 @@ public final class MessageTypeProto {
|
|||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\026MessageTypeProto.proto\022\032com.ljsd.jieli" +
|
||||
"ng.protocols*\213\272\002\n\013MessageType\022\027\n\022HEART_B" +
|
||||
"ng.protocols*\254\272\002\n\013MessageType\022\027\n\022HEART_B" +
|
||||
"EAT_REQUEST\020\350\007\022\030\n\023HEART_BEAT_RESPONSE\020\351\007" +
|
||||
"\022\036\n\031ACTIVITE_WORKSHOP_REQUEST\020\224N\022\037\n\032ACTI" +
|
||||
"VITE_WORKSHOP_RESPONSE\020\225N\022\027\n\022ARENA_INFO_" +
|
||||
|
|
@ -17390,7 +17407,8 @@ public final class MessageTypeProto {
|
|||
"8\022%\n\037VOUCHER_PRICE_BUY_GOODS_REQUEST\020\241\2438" +
|
||||
"\022\"\n\034VOUCHER_PRICE_GOODS_RESPONSE\020\242\2438\022\"\n\034" +
|
||||
"POWER_CENTER_INFO_INDICATION\020\244\2438\022\031\n\023HERO" +
|
||||
"_GET_INDICATION\020\245\2438B\002H\001"
|
||||
"_GET_INDICATION\020\245\2438\022\037\n\031GET_GOOGLE_COMMEN" +
|
||||
"T_REWARD\020\246\2438B\002H\001"
|
||||
};
|
||||
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
|
||||
new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
|
||||
|
|
|
|||
|
|
@ -166032,6 +166032,323 @@ public final class PlayerInfoProto {
|
|||
// @@protoc_insertion_point(class_scope:com.ljsd.jieling.protocols.ReceiveAccountVerifyReward)
|
||||
}
|
||||
|
||||
public interface GetGoogleCommentRewardRequestOrBuilder
|
||||
extends com.google.protobuf.MessageOrBuilder {
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code com.ljsd.jieling.protocols.GetGoogleCommentRewardRequest}
|
||||
*
|
||||
* <pre>
|
||||
*请求领取谷歌评价奖励
|
||||
* </pre>
|
||||
*/
|
||||
public static final class GetGoogleCommentRewardRequest extends
|
||||
com.google.protobuf.GeneratedMessage
|
||||
implements GetGoogleCommentRewardRequestOrBuilder {
|
||||
// Use GetGoogleCommentRewardRequest.newBuilder() to construct.
|
||||
private GetGoogleCommentRewardRequest(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
this.unknownFields = builder.getUnknownFields();
|
||||
}
|
||||
private GetGoogleCommentRewardRequest(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }
|
||||
|
||||
private static final GetGoogleCommentRewardRequest defaultInstance;
|
||||
public static GetGoogleCommentRewardRequest getDefaultInstance() {
|
||||
return defaultInstance;
|
||||
}
|
||||
|
||||
public GetGoogleCommentRewardRequest getDefaultInstanceForType() {
|
||||
return defaultInstance;
|
||||
}
|
||||
|
||||
private final com.google.protobuf.UnknownFieldSet unknownFields;
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return this.unknownFields;
|
||||
}
|
||||
private GetGoogleCommentRewardRequest(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
initFields();
|
||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!parseUnknownField(input, unknownFields,
|
||||
extensionRegistry, tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw e.setUnfinishedMessage(this);
|
||||
} catch (java.io.IOException e) {
|
||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this);
|
||||
} finally {
|
||||
this.unknownFields = unknownFields.build();
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return com.ljsd.jieling.protocols.PlayerInfoProto.internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.ljsd.jieling.protocols.PlayerInfoProto.internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest.class, com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest.Builder.class);
|
||||
}
|
||||
|
||||
public static com.google.protobuf.Parser<GetGoogleCommentRewardRequest> PARSER =
|
||||
new com.google.protobuf.AbstractParser<GetGoogleCommentRewardRequest>() {
|
||||
public GetGoogleCommentRewardRequest parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return new GetGoogleCommentRewardRequest(input, extensionRegistry);
|
||||
}
|
||||
};
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<GetGoogleCommentRewardRequest> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
private void initFields() {
|
||||
}
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized != -1) return isInitialized == 1;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
getSerializedSize();
|
||||
getUnknownFields().writeTo(output);
|
||||
}
|
||||
|
||||
private int memoizedSerializedSize = -1;
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSerializedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
size += getUnknownFields().getSerializedSize();
|
||||
memoizedSerializedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
@java.lang.Override
|
||||
protected java.lang.Object writeReplace()
|
||||
throws java.io.ObjectStreamException {
|
||||
return super.writeReplace();
|
||||
}
|
||||
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public static Builder newBuilder() { return Builder.create(); }
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder(com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest prototype) {
|
||||
return newBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() { return newBuilder(this); }
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code com.ljsd.jieling.protocols.GetGoogleCommentRewardRequest}
|
||||
*
|
||||
* <pre>
|
||||
*请求领取谷歌评价奖励
|
||||
* </pre>
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder>
|
||||
implements com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequestOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return com.ljsd.jieling.protocols.PlayerInfoProto.internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return com.ljsd.jieling.protocols.PlayerInfoProto.internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest.class, com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
private static Builder create() {
|
||||
return new Builder();
|
||||
}
|
||||
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
return this;
|
||||
}
|
||||
|
||||
public Builder clone() {
|
||||
return create().mergeFrom(buildPartial());
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return com.ljsd.jieling.protocols.PlayerInfoProto.internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_descriptor;
|
||||
}
|
||||
|
||||
public com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest getDefaultInstanceForType() {
|
||||
return com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest.getDefaultInstance();
|
||||
}
|
||||
|
||||
public com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest build() {
|
||||
com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest buildPartial() {
|
||||
com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest result = new com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest(this);
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest) {
|
||||
return mergeFrom((com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest other) {
|
||||
if (other == com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest.getDefaultInstance()) return this;
|
||||
this.mergeUnknownFields(other.getUnknownFields());
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (com.ljsd.jieling.protocols.PlayerInfoProto.GetGoogleCommentRewardRequest) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:com.ljsd.jieling.protocols.GetGoogleCommentRewardRequest)
|
||||
}
|
||||
|
||||
static {
|
||||
defaultInstance = new GetGoogleCommentRewardRequest(true);
|
||||
defaultInstance.initFields();
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:com.ljsd.jieling.protocols.GetGoogleCommentRewardRequest)
|
||||
}
|
||||
|
||||
private static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_com_ljsd_jieling_protocols_ErrorMsgResponse_descriptor;
|
||||
private static
|
||||
|
|
@ -167247,6 +167564,11 @@ public final class PlayerInfoProto {
|
|||
private static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_com_ljsd_jieling_protocols_ReceiveAccountVerifyReward_fieldAccessorTable;
|
||||
private static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_descriptor;
|
||||
private static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_fieldAccessorTable;
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
|
|
@ -167785,7 +168107,8 @@ public final class PlayerInfoProto {
|
|||
"ardRequest\022\014\n\004type\030\001 \001(\005\"+\n\021AccountVerif" +
|
||||
"yInfo\022\026\n\016receivedReward\030\001 \001(\010\"N\n\032Receive" +
|
||||
"AccountVerifyReward\0220\n\006reward\030\001 \001(\0132 .co" +
|
||||
"m.ljsd.jieling.protocols.DropB\002H\001"
|
||||
"m.ljsd.jieling.protocols.Drop\"\037\n\035GetGoog",
|
||||
"leCommentRewardRequestB\002H\001"
|
||||
};
|
||||
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
|
||||
new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
|
||||
|
|
@ -169250,6 +169573,12 @@ public final class PlayerInfoProto {
|
|||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_com_ljsd_jieling_protocols_ReceiveAccountVerifyReward_descriptor,
|
||||
new java.lang.String[] { "Reward", });
|
||||
internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_descriptor =
|
||||
getDescriptor().getMessageTypes().get(243);
|
||||
internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_com_ljsd_jieling_protocols_GetGoogleCommentRewardRequest_descriptor,
|
||||
new java.lang.String[] { });
|
||||
return null;
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -0,0 +1,25 @@
|
|||
package com.ljsd.jieling.handler.player;
|
||||
|
||||
import com.ljsd.battle.handler.BaseHandler;
|
||||
import com.ljsd.jieling.logic.player.PlayerLogic;
|
||||
import com.ljsd.jieling.netty.cocdex.PacketNetData;
|
||||
import com.ljsd.jieling.network.session.ISession;
|
||||
import com.ljsd.jieling.protocols.MessageTypeProto;
|
||||
|
||||
public class GetGoogleCommentRewardHandler extends BaseHandler {
|
||||
@Override
|
||||
public MessageTypeProto.MessageType getMessageCode() {
|
||||
return MessageTypeProto.MessageType.GET_GOOGLE_COMMENT_REWARD;
|
||||
}
|
||||
|
||||
/**
|
||||
* 处理谷歌评论奖励
|
||||
* @param iSession
|
||||
* @param netData
|
||||
* @throws Exception
|
||||
*/
|
||||
@Override
|
||||
public void process(ISession iSession, PacketNetData netData) throws Exception {
|
||||
PlayerLogic.getInstance().dealGoogleCommentReward(iSession);
|
||||
}
|
||||
}
|
||||
|
|
@ -241,6 +241,8 @@ public class PlayerManager extends MongoBase {
|
|||
}
|
||||
//榜单结算奖励信息,key为榜单类型,value为最后领取榜单结算奖励的时间,每次登录要把在结算时间范围内的榜单全部领取
|
||||
public Map<Integer,Integer> rankRewards = new HashMap<Integer,Integer>();
|
||||
//是否领取了谷歌评论的奖励
|
||||
int isGoogleCommentReward;
|
||||
|
||||
public Map<Integer, Integer> getRankRewards() {
|
||||
return rankRewards;
|
||||
|
|
@ -1362,4 +1364,14 @@ public class PlayerManager extends MongoBase {
|
|||
this.refreshPrivilegeCardTime = refreshPrivilegeCardTime;
|
||||
updateString("refreshPrivilegeCardTime",refreshPrivilegeCardTime);
|
||||
}
|
||||
|
||||
public int getIsGoogleCommentReward() {
|
||||
return isGoogleCommentReward;
|
||||
}
|
||||
|
||||
public void setIsGoogleCommentReward(int isGoogleCommentReward) {
|
||||
this.isGoogleCommentReward = isGoogleCommentReward;
|
||||
updateString("isGoogleCommentReward",isGoogleCommentReward);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1893,4 +1893,29 @@ public class PlayerLogic {
|
|||
}
|
||||
return rewardStr;
|
||||
}
|
||||
|
||||
/**
|
||||
* 处理google评论奖励
|
||||
* @param iSession
|
||||
* @throws Exception
|
||||
*/
|
||||
public void dealGoogleCommentReward(ISession iSession) throws Exception {
|
||||
int userId = iSession.getUid();
|
||||
User user = UserManager.getUser(userId);
|
||||
int isGet = user.getPlayerInfoManager().getIsGoogleCommentReward();
|
||||
//已经领取过了
|
||||
if(isGet == 1){
|
||||
return;
|
||||
}
|
||||
//暂时写死谷歌评论的礼包id为590002
|
||||
SRechargeCommodityConfig config = SRechargeCommodityConfig.getConfigById(590002);
|
||||
if(config == null){
|
||||
return;
|
||||
}
|
||||
//发奖
|
||||
String rewardStr = getRewardStr(false, config, 0);
|
||||
MailLogic.getInstance().sendMail(user.getId(),SErrorCodeEerverConfig.getI18NMessage("Google_Comment_title"),
|
||||
SErrorCodeEerverConfig.getI18NMessage("Google_Comment_txt"),rewardStr,TimeUtils.nowInt(),Global.MAIL_EFFECTIVE_TIME);
|
||||
user.getPlayerInfoManager().setIsGoogleCommentReward(1);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue