爱玩信息上报

back_recharge
duhui 2022-04-12 17:55:10 +08:00
parent 1354ec8bf3
commit 8b655778b9
1 changed files with 9 additions and 2 deletions

View File

@ -3,7 +3,9 @@ package com.ljsd.jieling.logic;
import com.ljsd.GameApplication;
import com.ljsd.jieling.config.reportData.DataMessageUtils;
import com.ljsd.jieling.logic.dao.PlayerManager;
import com.ljsd.jieling.logic.dao.TeamEnum;
import com.ljsd.jieling.logic.dao.root.User;
import com.ljsd.jieling.logic.hero.HeroLogic;
import com.ljsd.jieling.util.http.HttpPool;
import org.apache.commons.codec.digest.DigestUtils;
import org.slf4j.Logger;
@ -53,7 +55,12 @@ public class AiWanPlayerInfoUpload {
return;
}
PlayerManager playerInfoManager = user.getPlayerInfoManager();
int force = HeroLogic.getInstance().calTeamTotalForce(user, TeamEnum.FORMATION_NORMAL.getTeamId(), false);
int nowInt = TimeUtils.nowInt();
SortedMap<String, Object> extMap = new TreeMap<>();
extMap.put("power",force);
extMap.put("stage",user.getMainLevelManager().getFightId());
SortedMap<String, Object> map = new TreeMap<>();
map.put("eventtype",type);
map.put("appid",app_id);
@ -63,8 +70,8 @@ public class AiWanPlayerInfoUpload {
map.put("nickname",playerInfoManager.getNickName());
map.put("regtime",(playerInfoManager.getCreateTime()/1000));
map.put("posttime",nowInt);
map.put("level",user.getMainLevelManager().getFightId());//关卡
map.put("ext","");
map.put("level",playerInfoManager.getLevel());
map.put("ext",DataMessageUtils.gson.toJson(extMap));
String sign = getSign(map);
map.put("sign",sign);
String result = HttpPool.sendPost2(url, DataMessageUtils.gson.toJson(map));