✨ feat(gvg): 投石车攻击对手范围调整
This commit is contained in:
@@ -15,7 +15,7 @@ import { gameData, getReviveGold } from '../../../pubUtils/data';
|
||||
import { getAllServerName } from '../../../services/redisService';
|
||||
import { checkBattleHeroesByHid } from '../../../services/normalBattleService';
|
||||
import { SaveTeamParam, SaveTeamUpdateParam } from '../../../domain/gvgField/gvgDb';
|
||||
import { GVG_AREA_TYPE, GVG_ITEM, GVG_PERIOD, GVG_REC_TYPE, ITEM_CHANGE_REASON, PUSH_ROUTE, REDIS_KEY, STATUS } from '../../../consts';
|
||||
import { GVG_AREA_TYPE, GVG_ATTACK_TYPE, GVG_ITEM, GVG_PERIOD, GVG_REC_TYPE, ITEM_CHANGE_REASON, PUSH_ROUTE, REDIS_KEY, STATUS } from '../../../consts';
|
||||
import { GVGHeroInfo } from '../../../domain/dbGeneral';
|
||||
import { ArtifactModel } from '../../../db/Artifact';
|
||||
import { getHeroesAttributes } from '../../../services/playerCeService';
|
||||
@@ -561,7 +561,7 @@ export class GVGBattleHandler {
|
||||
|
||||
await battleEndSendMessage(groupKey, cityId, defenseTeam, attackTeam);
|
||||
await sendMessageToGVGAreaByTeamWithSuc(groupKey, defenseTeam.areaId, PUSH_ROUTE.GVG_TEAM_ATTACKED, {
|
||||
cityId, areaId: defenseTeam.areaId, attackType: 2, teams: [new GVGTeamInList(defenseTeam), new GVGTeamInList(attackTeam)]
|
||||
cityId, areaId: defenseTeam.areaId, attackType: GVG_ATTACK_TYPE.KNIFE, teams: [new GVGTeamInList(defenseTeam), new GVGTeamInList(attackTeam)]
|
||||
});
|
||||
return resResult(STATUS.SUCCESS, { curTeam: new MyTeamInfo(attackTeam), oppTeam: new MyTeamInfo(defenseTeam) });
|
||||
}
|
||||
@@ -645,13 +645,11 @@ export class GVGBattleHandler {
|
||||
const points = await GVGCityAreaPointModel.findByConfig(configId, groupKey);
|
||||
|
||||
let result: { cityId: number, guardLeagueName: string, areas: { areaId: number, points: { pointId: number, guardLeagueName: string }[] }[] }[] = [];
|
||||
for(let [ cityId, { mapType, areaIds }] of gameData.gvgCity) {
|
||||
for(let [ cityId, { mapType, battleAreaIds }] of gameData.gvgCity) {
|
||||
if(mapType != serverType) continue;
|
||||
let city = cities.find(cur => cur.cityId == cityId);
|
||||
let areas: { areaId: number, points: {pointId: number, guardLeagueName: string }[]}[] = [];
|
||||
for(let areaId of areaIds) {
|
||||
let dicArea = gameData.gvgArea.get(areaId);
|
||||
if(!dicArea || (dicArea.areaType != GVG_AREA_TYPE.BIG && dicArea.areaType != GVG_AREA_TYPE.MIDDLE && dicArea.areaType != GVG_AREA_TYPE.SMALL) ) continue;
|
||||
for(let areaId of battleAreaIds) {
|
||||
let pointIds = gameData.gvgPointByAreaId.get(areaId)||[];
|
||||
let pointArrs: { pointId: number, guardLeagueName: string }[] = [];
|
||||
for(let pointId of pointIds) {
|
||||
|
||||
Reference in New Issue
Block a user