//------------------------------------------------------------------------------
//
// This code was generated by a tool.
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
//
//------------------------------------------------------------------------------
using Bright.Serialization;
using System.Collections.Generic;
using SimpleJSON;
namespace cfg
{
///
/// 鱼缸建造活动参数
///
public sealed partial class EventPartnerConfig : Bright.Config.BeanBase
{
public JSONNode json;
public EventPartnerConfig(JSONNode _json)
{
{ if(!_json["RobotAcceptProb"].IsNumber) { throw new SerializationException(); } RobotAcceptProb = _json["RobotAcceptProb"]; }
{ var __json0 = _json["RobotAcceptTime"]; if(!__json0.IsArray) { throw new SerializationException(); } RobotAcceptTime = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } RobotAcceptTime.Add(__v0); } }
{ var __json0 = _json["RobotAgreeTime"]; if(!__json0.IsArray) { throw new SerializationException(); } RobotAgreeTime = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } RobotAgreeTime.Add(__v0); } }
{ if(!_json["RobotPointsMultiple"].IsNumber) { throw new SerializationException(); } RobotPointsMultiple = _json["RobotPointsMultiple"]; }
{ if(!_json["MatchAgreeTime"].IsNumber) { throw new SerializationException(); } MatchAgreeTime = _json["MatchAgreeTime"]; }
{ var __json0 = _json["FriendRecommendParam1"]; if(!__json0.IsArray) { throw new SerializationException(); } FriendRecommendParam1 = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } FriendRecommendParam1.Add(__v0); } }
{ var __json0 = _json["FriendRecommendParam2"]; if(!__json0.IsArray) { throw new SerializationException(); } FriendRecommendParam2 = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } FriendRecommendParam2.Add(__v0); } }
{ if(!_json["FriendRecommendListRefreshTime"].IsNumber) { throw new SerializationException(); } FriendRecommendListRefreshTime = _json["FriendRecommendListRefreshTime"]; }
{ if(!_json["RobotRecommendTriggerCount"].IsNumber) { throw new SerializationException(); } RobotRecommendTriggerCount = _json["RobotRecommendTriggerCount"]; }
{ if(!_json["RobotRecommendCount"].IsNumber) { throw new SerializationException(); } RobotRecommendCount = _json["RobotRecommendCount"]; }
{ var __json0 = _json["RobotDailyActiveTimeWindow"]; if(!__json0.IsArray) { throw new SerializationException(); } RobotDailyActiveTimeWindow = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } RobotDailyActiveTimeWindow.Add(__v0); } }
{ var __json0 = _json["RobotSingleAddPointsTimeWindow"]; if(!__json0.IsArray) { throw new SerializationException(); } RobotSingleAddPointsTimeWindow = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } RobotSingleAddPointsTimeWindow.Add(__v0); } }
{ var __json0 = _json["RobotSingleAddPointsOperations"]; if(!__json0.IsArray) { throw new SerializationException(); } RobotSingleAddPointsOperations = new System.Collections.Generic.List(__json0.Count); foreach(JSONNode __e0 in __json0.Children) { int __v0; { if(!__e0.IsNumber) { throw new SerializationException(); } __v0 = __e0; } RobotSingleAddPointsOperations.Add(__v0); } }
{ if(!_json["RobotMaxActivationCountPer24h"].IsNumber) { throw new SerializationException(); } RobotMaxActivationCountPer24h = _json["RobotMaxActivationCountPer24h"]; }
json = _json;
PostInit();
}
public EventPartnerConfig(float RobotAcceptProb, System.Collections.Generic.List RobotAcceptTime, System.Collections.Generic.List RobotAgreeTime, int RobotPointsMultiple, int MatchAgreeTime, System.Collections.Generic.List FriendRecommendParam1, System.Collections.Generic.List FriendRecommendParam2, int FriendRecommendListRefreshTime, int RobotRecommendTriggerCount, float RobotRecommendCount, System.Collections.Generic.List RobotDailyActiveTimeWindow, System.Collections.Generic.List RobotSingleAddPointsTimeWindow, System.Collections.Generic.List RobotSingleAddPointsOperations, int RobotMaxActivationCountPer24h )
{
this.RobotAcceptProb = RobotAcceptProb;
this.RobotAcceptTime = RobotAcceptTime;
this.RobotAgreeTime = RobotAgreeTime;
this.RobotPointsMultiple = RobotPointsMultiple;
this.MatchAgreeTime = MatchAgreeTime;
this.FriendRecommendParam1 = FriendRecommendParam1;
this.FriendRecommendParam2 = FriendRecommendParam2;
this.FriendRecommendListRefreshTime = FriendRecommendListRefreshTime;
this.RobotRecommendTriggerCount = RobotRecommendTriggerCount;
this.RobotRecommendCount = RobotRecommendCount;
this.RobotDailyActiveTimeWindow = RobotDailyActiveTimeWindow;
this.RobotSingleAddPointsTimeWindow = RobotSingleAddPointsTimeWindow;
this.RobotSingleAddPointsOperations = RobotSingleAddPointsOperations;
this.RobotMaxActivationCountPer24h = RobotMaxActivationCountPer24h;
PostInit();
}
public static EventPartnerConfig DeserializeEventPartnerConfig(JSONNode _json)
{
return new EventPartnerConfig(_json);
}
///
/// 机器人接受邀请概率
///
public float RobotAcceptProb { get; private set; }
///
/// 机器人接受邀请时间(单位:秒)
///
public System.Collections.Generic.List RobotAcceptTime { get; private set; }
///
/// 机器人同意时间(单位:秒)
///
public System.Collections.Generic.List RobotAgreeTime { get; private set; }
///
/// 加的分必须是配置值的整数倍
///
public int RobotPointsMultiple { get; private set; }
///
/// 匹配成功后,等待X秒默认接受
///
public int MatchAgreeTime { get; private set; }
///
/// 活跃好友数量
///
public System.Collections.Generic.List FriendRecommendParam1 { get; private set; }
///
/// 推荐伙伴数量
///
public System.Collections.Generic.List FriendRecommendParam2 { get; private set; }
///
/// 推荐伙伴列表刷新时间(单位:秒)
///
public int FriendRecommendListRefreshTime { get; private set; }
///
/// 用户发出N次邀请后,开始推荐机器人
///
public int RobotRecommendTriggerCount { get; private set; }
///
/// 机器人占推荐列表的比例
///
public float RobotRecommendCount { get; private set; }
///
/// 机器人单日活跃时间段(单位:秒)
///
public System.Collections.Generic.List RobotDailyActiveTimeWindow { get; private set; }
///
/// 机器人单次集中加分时间段(单位:秒)
///
public System.Collections.Generic.List RobotSingleAddPointsTimeWindow { get; private set; }
///
/// 机器人单次加分,分几次完成
///
public System.Collections.Generic.List RobotSingleAddPointsOperations { get; private set; }
///
/// 机器人每24小时最多激活几次
///
public int RobotMaxActivationCountPer24h { get; private set; }
public const int __ID__ = 1203476944;
public override int GetTypeId() => __ID__;
public void Resolve(Dictionary _tables)
{
PostResolve();
}
public void TranslateText(System.Func translator)
{
}
public override string ToString()
{
return "{ "
+ "RobotAcceptProb:" + RobotAcceptProb + ","
+ "RobotAcceptTime:" + Bright.Common.StringUtil.CollectionToString(RobotAcceptTime) + ","
+ "RobotAgreeTime:" + Bright.Common.StringUtil.CollectionToString(RobotAgreeTime) + ","
+ "RobotPointsMultiple:" + RobotPointsMultiple + ","
+ "MatchAgreeTime:" + MatchAgreeTime + ","
+ "FriendRecommendParam1:" + Bright.Common.StringUtil.CollectionToString(FriendRecommendParam1) + ","
+ "FriendRecommendParam2:" + Bright.Common.StringUtil.CollectionToString(FriendRecommendParam2) + ","
+ "FriendRecommendListRefreshTime:" + FriendRecommendListRefreshTime + ","
+ "RobotRecommendTriggerCount:" + RobotRecommendTriggerCount + ","
+ "RobotRecommendCount:" + RobotRecommendCount + ","
+ "RobotDailyActiveTimeWindow:" + Bright.Common.StringUtil.CollectionToString(RobotDailyActiveTimeWindow) + ","
+ "RobotSingleAddPointsTimeWindow:" + Bright.Common.StringUtil.CollectionToString(RobotSingleAddPointsTimeWindow) + ","
+ "RobotSingleAddPointsOperations:" + Bright.Common.StringUtil.CollectionToString(RobotSingleAddPointsOperations) + ","
+ "RobotMaxActivationCountPer24h:" + RobotMaxActivationCountPer24h + ","
+ "}";
}
partial void PostInit();
partial void PostResolve();
}
}