✨ feat(拍卖行): 拍卖行最后10s延长15s
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
import { DividendModel, DividendType } from './../../../db/Dividend';
|
||||
import { Application, BackendSession, ChannelService, HandlerService, pinus, } from "pinus";
|
||||
import { AUCTION_STAGE, DEBUG_MAGIC_WORD, STATUS, CURRENCY_BY_TYPE, CURRENCY_TYPE, DATA_NAME, LOT_STATUS, CHANNEL_PREFIX, MAIL_TYPE, ITEM_CHANGE_REASON, TA_EVENT, ROLE_RECEIVE_STATUS, PUSH_ROUTE } from "../../../consts";
|
||||
import { LotModel } from "../../../db/Lot";
|
||||
import { AUCTION_STAGE, DEBUG_MAGIC_WORD, STATUS, CURRENCY_BY_TYPE, CURRENCY_TYPE, DATA_NAME, LOT_STATUS, CHANNEL_PREFIX, MAIL_TYPE, ITEM_CHANGE_REASON, TA_EVENT, ROLE_RECEIVE_STATUS, PUSH_ROUTE, AUCTION_BID_EXTEND_TIME } from "../../../consts";
|
||||
import { LotModel, LotParam } from "../../../db/Lot";
|
||||
import { ItemReward } from "../../../domain/dbGeneral";
|
||||
import { genCode, resResult } from "../../../pubUtils/util";
|
||||
import { auctionStage, calculateDividend, genAuction, sendUngotDividend, startGuildAuction, startWorldAuction, stopAuction, todayGuildBegin, getBasePrice, debugAuctionLots, officialAuctionLots, auctionBidStatus, getMaxPrice, guildBidStatus, getAuction, pushAuctionOver, pushAuctionUpdate, checkAuctionStage, processDividendFormat, processSingleDividendFormat, tomorrowGuildBegin, processLotsFormat, processSingleLotFormat, getAuctionRewardByPoolId } from "../../../services/auctionService";
|
||||
import { auctionStage, calculateDividend, genAuction, sendUngotDividend, startGuildAuction, startWorldAuction, stopAuction, todayGuildBegin, getBasePrice, debugAuctionLots, officialAuctionLots, auctionBidStatus, getMaxPrice, guildBidStatus, getAuction, pushAuctionOver, pushAuctionUpdate, processDividendFormat, processSingleDividendFormat, tomorrowGuildBegin, processLotsFormat, processSingleLotFormat, getAuctionRewardByPoolId, getLotStatus, extendLotTime } from "../../../services/auctionService";
|
||||
import { addItems, getGoldObject, handleCost } from '../../../services/role/rewardService';
|
||||
import { getSimpleRoleInfo } from '../../../services/roleService';
|
||||
import { getRoleOnlineInfo } from '../../../services/redisService';
|
||||
@@ -76,12 +76,12 @@ export class AuctionHandler {
|
||||
return resResult(STATUS.AUCTION_GUILD_MEMBER_ONLY);
|
||||
}
|
||||
|
||||
if(!await checkAuctionStage(auctionStage, magicWord)) {
|
||||
let { curBuyer, curPrice, prePrice, maxPrice, gid, count, bidRoles, watchingRoles, seq, begin, auctionStage: lotAuctionStage } = lot;
|
||||
if (auctionStage != lotAuctionStage) {
|
||||
res.releaseCallback();
|
||||
return resResult(STATUS.AUCITON_STAGE_ERR);
|
||||
}
|
||||
|
||||
let { curBuyer, curPrice, prePrice, maxPrice, gid, count, bidRoles, watchingRoles, seq, begin } = lot;
|
||||
if (curBuyer === roleId && !max) {
|
||||
res.releaseCallback();
|
||||
return resResult(STATUS.LOT_OFFER_SERIAL);
|
||||
@@ -117,7 +117,11 @@ export class AuctionHandler {
|
||||
reportTAEvent(roleId, TA_EVENT.AUCTION_ITEM_GET, { item_name: dicGoods?.name, item_count: count, deel_price: newPrice }, ip);
|
||||
}
|
||||
bidRoles.push({ roleId, price: newPrice, time: new Date() });
|
||||
const newLot = await LotModel.updateLot({ code, curBuyer: roleId, curPrice: newPrice, auctionStage, prePrice: curPrice, bidRoles, status: max ? LOT_STATUS.MAX : (maxFlag ? LOT_STATUS.SOLD : LOT_STATUS.ING), watchingRoles: Array.from(new Set([...watchingRoles, roleId])), seq: 0 });
|
||||
let lotStatus = await getLotStatus(auctionStage, max, maxFlag)
|
||||
let update: LotParam = { code, curBuyer: roleId, curPrice: newPrice, auctionStage, prePrice: curPrice, bidRoles, status: lotStatus, watchingRoles: Array.from(new Set([...watchingRoles, roleId])), seq: 0 };
|
||||
if(lotStatus == LOT_STATUS.BIDDING) update.end = new Date(Date.now() + AUCTION_BID_EXTEND_TIME * 1000);
|
||||
const newLot = await LotModel.updateLot(update);
|
||||
await extendLotTime(newLot);
|
||||
if(seq <= LOTS_KEEP_TO_WORLD_CNT && seq > 0) await LotModel.updateOne({ begin, gid, count, status: LOT_STATUS.DEFAULT, serverId, seq: { $gt: LOTS_KEEP_TO_WORLD_CNT } }, { $set: { seq }});
|
||||
await pushAuctionOver(newLot); // 推送竞价超过标志
|
||||
res.releaseCallback();
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { DividendModel } from './../db/Dividend';
|
||||
import { LOT_CODE_LEN, AUCTION_STAGE, AUCTION_TIME, DIVIDEND_CODE_LEN, DIVIDEND_STATUS, LOT_STATUS, MAIL_TYPE, CURRENCY_BY_TYPE, CURRENCY_TYPE, ROLE_RECEIVE_STATUS, AUCTION_BID_STATUS, DEBUG_MAGIC_WORD, AUCTION_SOURCE, TA_EVENT, getAuctionSourceTypeName, PUSH_ROUTE, GUILD_JOB } from './../consts';
|
||||
import { LOT_CODE_LEN, AUCTION_STAGE, AUCTION_TIME, DIVIDEND_CODE_LEN, DIVIDEND_STATUS, LOT_STATUS, MAIL_TYPE, CURRENCY_BY_TYPE, CURRENCY_TYPE, ROLE_RECEIVE_STATUS, AUCTION_BID_STATUS, DEBUG_MAGIC_WORD, AUCTION_SOURCE, TA_EVENT, getAuctionSourceTypeName, PUSH_ROUTE, GUILD_JOB, AUCTION_BID_TIME, AUCTION_BID_EXTEND_TIME } from './../consts';
|
||||
import { DividendRec, } from "../domain/dbGeneral";
|
||||
import { genCode, getRandEelmWithWeight, getRandSingleEelm } from '../pubUtils/util';
|
||||
import Lot, { LotModel, LotParam, LotType } from '../db/Lot';
|
||||
@@ -20,6 +20,8 @@ import { pick } from 'underscore';
|
||||
import { AuctionRewardInter } from '../domain/battleField/auction';
|
||||
import { CounterLotsModel } from '../db/CounterAuction';
|
||||
import { isGoodsHidden } from './dataService';
|
||||
import { scheduleJob } from 'node-schedule';
|
||||
import { clearLotTimer, setLotTimer } from './memoryCache/auctionData';
|
||||
|
||||
// ! 获取底价,假数据
|
||||
export function getBasePrice(gid: number, count: number) {
|
||||
@@ -50,16 +52,9 @@ export async function debugAuctionLots(session: FrontendOrBackendSession, begin:
|
||||
export async function officialAuctionLots(session: FrontendOrBackendSession, begin: Date) {
|
||||
const serverId = session.get('serverId');
|
||||
const guildCode = session.get('guildCode');
|
||||
const stage = await auctionStage();
|
||||
let lots: LotType[] = [];
|
||||
if (stage === AUCTION_STAGE.DEFAULT || stage === AUCTION_STAGE.GUILD) {
|
||||
lots = await LotModel.findGuildLotsByBegin(guildCode, begin);
|
||||
} else if (stage === AUCTION_STAGE.WORLD) {
|
||||
lots = await LotModel.findWorldLotsByBegin(serverId, begin);
|
||||
}
|
||||
|
||||
|
||||
return processLotsFormat(lots);
|
||||
let guildLots = await LotModel.findGuildLotsByBegin(guildCode, begin);
|
||||
let serverLots = await LotModel.findWorldLotsByBegin(serverId, begin);
|
||||
return processLotsFormat([...guildLots, ...serverLots]);
|
||||
}
|
||||
|
||||
// 拍卖行开始时间 今天20:20
|
||||
@@ -342,7 +337,6 @@ export async function startWorldAuction() {
|
||||
let lots = await LotModel.setLotSoldByBegin(begin, AUCTION_STAGE.GUILD); // 正在竞拍的拍品
|
||||
await sendLotsRewardToMlail(lots);
|
||||
lots = await LotModel.keepUnSoldLotsToWorld(begin);
|
||||
let dividends = await DividendModel.updateDividendsStatus(begin, DIVIDEND_STATUS.END);
|
||||
|
||||
if(isDebugTime()) {
|
||||
let day = getCurDay();
|
||||
@@ -350,7 +344,7 @@ export async function startWorldAuction() {
|
||||
pinus.app.rpc.guild.guildActivityRemote.setCurrentTime.broadcast(time);
|
||||
await pushCurrentTime(time);
|
||||
}
|
||||
await pushAuctionUpdate(lots, dividends);
|
||||
await pushAuctionUpdate(lots, []);
|
||||
return true;
|
||||
} catch (e) {
|
||||
console.error('startWorldAuction err: ', e);
|
||||
@@ -358,6 +352,14 @@ export async function startWorldAuction() {
|
||||
}
|
||||
}
|
||||
|
||||
export async function startDividend() {
|
||||
console.log('schedule startDividend called:', new Date());
|
||||
const begin = await todayGuildBegin();
|
||||
console.log('begin', begin)
|
||||
let dividends = await DividendModel.updateDividendsStatus(begin, DIVIDEND_STATUS.END);
|
||||
await pushAuctionUpdate([], dividends);
|
||||
}
|
||||
|
||||
export async function stopAuction() {
|
||||
try {
|
||||
console.log('schedule stopAuction called:', new Date());
|
||||
@@ -492,35 +494,30 @@ export async function pushAuctionOver(lot: LotType) {
|
||||
}
|
||||
|
||||
export async function pushAuctionUpdate(lots: LotType[], dividends: DividendType[]) {
|
||||
const stage = await auctionStage();
|
||||
if(stage === AUCTION_STAGE.DEFAULT || stage === AUCTION_STAGE.GUILD) {
|
||||
let lotsResult = new Map<string, LotType[]>();
|
||||
let lotsByGuild = new Map<string, LotType[]>();
|
||||
let lotsByServer = new Map<number, LotType[]>();
|
||||
|
||||
for(let lot of lots) {
|
||||
if(!lotsResult.has(lot.guildCode)) {
|
||||
lotsResult.set(lot.guildCode, []);
|
||||
for(let lot of lots) {
|
||||
if(lot.auctionStage === AUCTION_STAGE.DEFAULT || lot.auctionStage === AUCTION_STAGE.GUILD) {
|
||||
if(!lotsByGuild.has(lot.guildCode)) {
|
||||
lotsByGuild.set(lot.guildCode, []);
|
||||
}
|
||||
lotsResult.get(lot.guildCode).push(lot);
|
||||
}
|
||||
|
||||
for(let [guildCode, lots] of lotsResult) {
|
||||
await sendMessageToGuildWithSuc(guildCode, PUSH_ROUTE.AUCTION_UPDATE, { lots: processLotsFormat(lots) });
|
||||
}
|
||||
|
||||
} else {
|
||||
let lotsResult = new Map<number, LotType[]>();
|
||||
for(let lot of lots) {
|
||||
|
||||
if(!lotsResult.has(lot.serverId)) {
|
||||
lotsResult.set(lot.serverId, []);
|
||||
lotsByGuild.get(lot.guildCode).push(lot);
|
||||
} else {
|
||||
if(!lotsByServer.has(lot.serverId)) {
|
||||
lotsByServer.set(lot.serverId, []);
|
||||
}
|
||||
lotsResult.get(lot.serverId).push(lot);
|
||||
}
|
||||
|
||||
for(let [serverId, lots] of lotsResult) {
|
||||
await sendMessageToServerWithSuc(serverId, PUSH_ROUTE.AUCTION_UPDATE, { lots: processLotsFormat(lots) });
|
||||
lotsByServer.get(lot.serverId).push(lot);
|
||||
}
|
||||
}
|
||||
|
||||
for(let [guildCode, lots] of lotsByGuild) {
|
||||
await sendMessageToGuildWithSuc(guildCode, PUSH_ROUTE.AUCTION_UPDATE, { lots: processLotsFormat(lots) });
|
||||
}
|
||||
for(let [serverId, lots] of lotsByServer) {
|
||||
await sendMessageToServerWithSuc(serverId, PUSH_ROUTE.AUCTION_UPDATE, { lots: processLotsFormat(lots) });
|
||||
}
|
||||
|
||||
let dividendsResult = new Map<string, DividendType[]>();
|
||||
for(let dividend of dividends) {
|
||||
if(!dividendsResult.has(dividend.guildCode)) {
|
||||
@@ -551,6 +548,45 @@ export async function checkAuctionStage(auctionStage: number, magicWord: string)
|
||||
return true
|
||||
}
|
||||
|
||||
export async function isAuctionBidding() {
|
||||
const curTime = await getCurrentTimeWithSetDay();
|
||||
const guildAuctionBeginTime = (await todayWorldBegin()).getTime();
|
||||
return guildAuctionBeginTime - curTime <= AUCTION_BID_TIME * 1000;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param max 玩家是否直接选择一口价
|
||||
* @param maxFlag 竞拍是否达到一口价的价格了
|
||||
* @param isBidding 是否在竞价时间重
|
||||
*/
|
||||
export async function getLotStatus(auctionStage: number, max: boolean, maxFlag: boolean) {
|
||||
if(max) return LOT_STATUS.MAX;
|
||||
if(maxFlag) return LOT_STATUS.SOLD;
|
||||
|
||||
if(auctionStage == AUCTION_STAGE.GUILD && await isAuctionBidding()) return LOT_STATUS.BIDDING;
|
||||
return LOT_STATUS.ING
|
||||
}
|
||||
|
||||
export async function extendLotTime(lot: LotType) {
|
||||
if(lot.status != LOT_STATUS.BIDDING) {
|
||||
clearLotTimer(lot.code);
|
||||
} else {
|
||||
let timer = setTimeout(async () => {
|
||||
await sendSingleLot(lot.code);
|
||||
}, lot.end.getTime() - Date.now());
|
||||
setLotTimer(lot.code, timer);
|
||||
}
|
||||
}
|
||||
|
||||
export async function sendSingleLot(code: string) {
|
||||
console.log('schedule sendSingleLot called:', new Date());
|
||||
let lot = await LotModel.setLotSold(code, AUCTION_STAGE.GUILD); // 正在竞拍的拍品
|
||||
await sendLotsRewardToMlail([lot]);
|
||||
await pushAuctionOver(lot);
|
||||
return true;
|
||||
}
|
||||
|
||||
export function processSingleDividendFormat(dividend: DividendType) {
|
||||
if(!dividend) return null;
|
||||
let newDividend = { ...dividend, begin: getSeconds(dividend.begin)}
|
||||
@@ -615,4 +651,8 @@ export function getAuctionRewardByPoolId(poolId: number) {
|
||||
}
|
||||
}
|
||||
return rewards;
|
||||
}
|
||||
|
||||
export function biddingLotTimeout() {
|
||||
scheduleJob('', () => {})
|
||||
}
|
||||
@@ -709,6 +709,7 @@ export async function setDicAuctionTime(startTime: number, endActivity: number,
|
||||
let endGuildDate = new Date(startGuildDate.getTime() + endGuild * 1000);
|
||||
let startWorldDate = new Date(endGuildDate.getTime() + startWorld * 1000);
|
||||
let endWorldDate = new Date(startWorldDate.getTime() + endWorld * 1000);
|
||||
let startDividendData = new Date(startWorldDate.getTime() + 3 * 60 * 1000)
|
||||
|
||||
|
||||
// console.log('********* setDicAuctionTime', startGuildDate, endGuildDate, startWorldDate, endWorldDate);
|
||||
@@ -719,6 +720,7 @@ export async function setDicAuctionTime(startTime: number, endActivity: number,
|
||||
gameData.auctionTime.set(AUCTION_TIME.WORLD_PREVIEW, formatTime(endGuildDate));
|
||||
gameData.auctionTime.set(AUCTION_TIME.WORLD_OPEN, formatTime(startWorldDate));
|
||||
gameData.auctionTime.set(AUCTION_TIME.WORLD_CLOSE, formatTime(endWorldDate));
|
||||
gameData.auctionTime.set(AUCTION_TIME.DIVIDEND_START, formatTime(startDividendData));
|
||||
|
||||
// console.log('*********** setDicAuctionTime', gameData.auctionTime)
|
||||
}
|
||||
|
||||
21
game-server/app/services/memoryCache/auctionData.ts
Normal file
21
game-server/app/services/memoryCache/auctionData.ts
Normal file
@@ -0,0 +1,21 @@
|
||||
let auctionTimer = new Map<string, NodeJS.Timer>();
|
||||
|
||||
export function getLotTimer(code: string) {
|
||||
return auctionTimer.get(code)
|
||||
}
|
||||
|
||||
export function setLotTimer(code: string, timer: NodeJS.Timer) {
|
||||
if(auctionTimer.has(code)) {
|
||||
let originTimer = auctionTimer.get(code);
|
||||
if(originTimer) clearTimeout(originTimer);
|
||||
}
|
||||
auctionTimer.set(code, timer);
|
||||
}
|
||||
|
||||
export function clearLotTimer(code: string) {
|
||||
let timer = getLotTimer(code);
|
||||
if (timer) {
|
||||
clearTimeout(timer);
|
||||
auctionTimer.delete(code)
|
||||
}
|
||||
}
|
||||
@@ -10,7 +10,7 @@ import { pinus } from 'pinus';
|
||||
import { settleGuildWeekly } from './guildService';
|
||||
import { sendMailByContent, SendMailFun, sendMailsByGmMail, } from './mailService';
|
||||
import { sendEndMsgToAllServer, sendGuildActivityStatus, setPreDayActiveData, incCurGuildActivityIndex } from './guildActivity/guildActivityService';
|
||||
import { sendUngotDividendJob, startGuildAuction, startWorldAuction, stopAuction } from './auctionService';
|
||||
import { sendUngotDividendJob, startGuildAuction, startWorldAuction, stopAuction, startDividend } from './auctionService';
|
||||
import { DicGuildActivity } from '../pubUtils/dictionary/DicGuildActivity';
|
||||
import { dispatch } from '../pubUtils/dispatcher';
|
||||
import { initMarquee, setServerMainten } from './gmService';
|
||||
@@ -427,18 +427,21 @@ export async function raceActivitySeconds() {
|
||||
let startGuildAuctionJobId: Job;
|
||||
let startWorldAuctionJobId: Job;
|
||||
let stopAuctionJobId: Job;
|
||||
let startDividendJobId: Job;
|
||||
|
||||
export async function auctionSchedule() {
|
||||
clearAuctionSchedule();
|
||||
let guildOpen = gameData.auctionTime.get(AUCTION_TIME.GUILD_OPEN);
|
||||
let worldOpen = gameData.auctionTime.get(AUCTION_TIME.WORLD_OPEN);
|
||||
let worldClose = gameData.auctionTime.get(AUCTION_TIME.WORLD_CLOSE);
|
||||
let dividendStart = gameData.auctionTime.get(AUCTION_TIME.DIVIDEND_START);
|
||||
|
||||
// console.log('***** auctionSchedule', guildOpen.hour, guildOpen.minute, guildOpen.seconds);
|
||||
// console.log('***** auctionSchedule', worldOpen.hour, worldOpen.minute, worldOpen.seconds);
|
||||
// console.log('***** auctionSchedule', worldClose.hour, worldClose.minute, worldClose.seconds);
|
||||
startGuildAuctionJobId = scheduleJob('startGuildAuction', `${guildOpen.seconds} ${guildOpen.minute} ${guildOpen.hour} * * ?`, startGuildAuction);
|
||||
startWorldAuctionJobId = scheduleJob('startWorldAuction', `${worldOpen.seconds} ${worldOpen.minute} ${worldOpen.hour} * * ?`, startWorldAuction);
|
||||
startDividendJobId = scheduleJob('startDividend', `${dividendStart.seconds} ${dividendStart.minute} ${dividendStart.hour} * * ?`, startDividend);
|
||||
stopAuctionJobId = scheduleJob('stopAuction', `${worldClose.seconds} ${worldClose.minute} ${worldClose.hour} * * ?`, stopAuction);
|
||||
|
||||
}
|
||||
|
||||
@@ -138,6 +138,13 @@ export async function guild(session: Session, msg: any, app: Application, cb: (e
|
||||
needDispatch = true;
|
||||
rid = `${groupId}_${arg.body.cityId}`;
|
||||
}
|
||||
} else if ([
|
||||
'guild.auctionHandler.offer'
|
||||
].indexOf(arg.route) != -1) {
|
||||
if(arg.body.code) {
|
||||
needDispatch = true;
|
||||
rid = arg.body.code;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,6 +23,7 @@ export enum AUCTION_TIME {
|
||||
WORLD_PREVIEW = 4, // 世界拍卖预览时间(非开启时间)
|
||||
WORLD_OPEN = 5, // 世界拍卖开启时间
|
||||
WORLD_CLOSE = 6, // 世界拍卖结束时间
|
||||
DIVIDEND_START = 7, // 可以领取分红的时间
|
||||
}
|
||||
|
||||
export const DIVIDEND_STATUS = {
|
||||
@@ -37,6 +38,7 @@ export const LOT_STATUS = {
|
||||
ING: 1, // 竞拍中
|
||||
SOLD: 2, // 竞拍成功
|
||||
MAX: 3, // 一口价
|
||||
BIDDING: 4, // 竞价中
|
||||
PASSIN: -1, // 流拍
|
||||
}
|
||||
|
||||
|
||||
@@ -319,4 +319,7 @@ export const CITY_ACTIVITY_DOOR = 1047;
|
||||
|
||||
export enum WISH_POOL_TYPE {
|
||||
SOUL = 1, // 将魂
|
||||
}
|
||||
}
|
||||
|
||||
export const AUCTION_BID_TIME = 30; // 倒计时10s前需要向后延长结算
|
||||
export const AUCTION_BID_EXTEND_TIME = 40; // 向后延长15s
|
||||
@@ -52,7 +52,7 @@ export default class Lot extends BaseModel {
|
||||
@prop({ required: true })
|
||||
end: Date; // 竞拍结束时间
|
||||
@prop({ required: true, default: 0 })
|
||||
status: number; // 拍品状态,0:无人竞拍;1:竞拍中;2:已竞拍;3:一口价
|
||||
status: number; // 拍品状态,0:无人竞拍;1:竞拍中;2:已竞拍;3:一口价 4:倒计时10s内
|
||||
@prop({ required: true, default: 0 })
|
||||
sort: number; // 排序
|
||||
@prop({ required: true, default: 0 })
|
||||
@@ -153,6 +153,11 @@ export default class Lot extends BaseModel {
|
||||
return results;
|
||||
}
|
||||
|
||||
public static async setLotSold(code: string, saveAuctionStage: number) {
|
||||
let lot: LotType = await LotModel.findOneAndUpdate({ code, status: LOT_STATUS.BIDDING }, { $set: { status: LOT_STATUS.SOLD, saveAuctionStage, sendMail: true } }, { new: true }).lean();
|
||||
return lot;
|
||||
}
|
||||
|
||||
public static async setSeq(begin: Date, gid: number, count: number, seq: number) {
|
||||
const results: LotType = await LotModel.findOneAndUpdate({ begin, gid, count, status: LOT_STATUS.DEFAULT }, { $set: { seq } }).sort({ seq: -1 }).select('-_id -__v').lean();
|
||||
return results;
|
||||
|
||||
@@ -899,6 +899,7 @@ function loadAuctionTime() {
|
||||
gameData.auctionTime.set(AUCTION_TIME.WORLD_PREVIEW, splitTime(param.AUCTION.WORLD_AUCTION_PREVIEW_TIME));
|
||||
gameData.auctionTime.set(AUCTION_TIME.WORLD_OPEN, splitTime(param.AUCTION.WORLD_AUCTION_OPEN_TIME));
|
||||
gameData.auctionTime.set(AUCTION_TIME.WORLD_CLOSE, splitTime(param.AUCTION.WORLD_AUCTION_CLOSE_TIME));
|
||||
gameData.auctionTime.set(AUCTION_TIME.DIVIDEND_START, splitTime(param.AUCTION.GUILD_AUCTION_BONUS_TIME));
|
||||
}
|
||||
|
||||
function splitTime(str: string) {
|
||||
|
||||
@@ -231,6 +231,7 @@ export const AUCTION = {
|
||||
WORLD_AUCTION_PREVIEW_TIME: '20:30:00', // 世界拍卖预览时间(非开启时间)
|
||||
WORLD_AUCTION_OPEN_TIME: '20:30:00', // 世界拍卖开启时间
|
||||
WORLD_AUCTION_CLOSE_TIME: '22:00:00', // 世界拍卖结束时间
|
||||
GUILD_AUCTION_BONUS_TIME: '20:35:00', // 军团拍卖分红领取时间
|
||||
};
|
||||
export const GUILD_BOSS = {
|
||||
GUILD_BOSS_OPEN_COUNT: 1, // 团长每天可以开启的次数
|
||||
@@ -348,17 +349,21 @@ export const ACTIVITY = {
|
||||
ACTIVITY_ZHUMING_CAST_NUMLIMIT: 12, // 朱明集会神兵铸造材料数量总上限
|
||||
ACTIVITY_FLIPCARD_SCORE: '1&50|21&30|25&25|29&15', // 翻拍小游戏的得分规则(min(含)&socre)区间下限至下一档之间的得分
|
||||
ACTIVITY_ARCHERY_SCORE: '0&0|1&1|2&1|3&1|4&1|5&1|6&1|7&2|8&3|9&4|10&5', // 射箭小游戏中的环数以及对应得分,环数(含)&得分
|
||||
ACTIVITY_EATTING_RICEDUMPLING_SPINE_POINT: '30&0&-5|80&1&-6|100&2&-7', // 进度阶段上限&额外加分&该阶段每0.1s进度条减少进度
|
||||
ACTIVITY_EATTING_RICEDUMPLING_TOTALCOUNT: 15, // 一个粽子图片=点击X下
|
||||
ACTIVITY_EATTING_RICEDUMPLING_SPINE_POINT: '30&0&-6|80&1&-8|100&2&-10', // 进度阶段上限&额外加分&该阶段每0.1s进度条减少进度
|
||||
ACTIVITY_EATTING_RICEDUMPLING_TOTALCOUNT: 25, // 一个粽子图片=点击X下
|
||||
ACTIVITY_EATTING_RICEDUMPLING_COUNTDOWN: 20, // 张飞吃粽子游戏倒计时(秒)
|
||||
ACTIVITY_EATTING_RICEDUMPLING_PROGRESS_SPEED: 10, // 点击1下进度条增加进度
|
||||
ACTIVITY_EATTING_RICEDUMPLING_PROGRESS_KEYPOINT: '30&80', // 张飞吃粽子进度条达到x进入狂暴模式动画
|
||||
ACTIVITY_EATTING_RICEDUMPLING_ROBOT_SPEED: '3&4', // 机器人每X秒少一个粽子图片/每X秒少一个粽子图片
|
||||
ACTIVITY_ARCHERY_SCORE_EXTRADD: '2&2&梅开二度|3&4&连中三元|4&8&技惊四座|5&16&绝世五连', // 连续X次10环&额外加分&文字提示
|
||||
ACTIVITY_ARCHERY_ONCE_NUM: 5, // 一轮射箭可射几箭
|
||||
ACTIVITY_CATCH_ZONGZI_COUNTDOWN: 20, // 接粽子游戏倒计时(秒)
|
||||
ACTIVITY_CATCH_ZONGZI_COUNTDOWN: 30, // 接粽子游戏倒计时(秒)
|
||||
ACTIVITY_CATCH_ZONGZI_PERSCREEN_COUNT: 10, // 接粽子小游戏一次掉落的粽子总数
|
||||
ACTIVITY_CATCH_ZONGZI_TYPE_RATIO: '1&0.8&1|2&0.2&2', // 粽子类型&掉落比例系数&得分 小粽子type=1 大粽子type=2
|
||||
ACTIVITY_CATCH_FISH_COUNTDOWN: 30, // 捕鱼游戏倒计时(秒)
|
||||
ACTIVITY_CATCH_FISH_SHOWSPEED: '0&1.5|3&2|10&2.2|20&1.8', // 每隔几秒出现一条鱼 前A秒(含)&每隔N秒出现鱼/前B秒(含)&每隔N秒出现鱼
|
||||
ACTIVITY_CATCH_FISH_PROBABILITY: '1&45|2&40|3&15', // 新出现的鱼是什么类型的概率 type&概率(type=1:小黑鱼 type=2:大黑鱼 type=3:锦鲤)
|
||||
ACTIVITY_WATERCHANNEL_SCORE: '1&50|6&30|9&25|16&15', // 水渠小游戏的得分规则(min(含)&socre)区间下限至下一档之间的得分
|
||||
};
|
||||
export const BATTLE_PREPARING = {
|
||||
CHANGE_ORDER_OPEN: 109, // 出兵界面行动顺序按钮开启关卡
|
||||
@@ -437,6 +442,7 @@ export const GVG = {
|
||||
GVG_DEFAULT_BATTLE_CD: 20, // 激战期战斗锁定时长,用于玩家退出时获取不到数据的情况
|
||||
GVG_VESTIGE_BUY_COST: '31002&200', // 单人遗迹购买挑战每次消耗
|
||||
GVG_VESTIGE_BUY_LIMIT: 10, // 单人遗迹购买挑战次数每日上限
|
||||
GVG_VESTIGE_LINEDOWN_HEROS: 6, // 遗迹驻扎阵容至少上阵人数
|
||||
};
|
||||
export const PLATFORM_CONFIG = {
|
||||
OPEN_ANIMATION: 1, // 0关,1开(开场动画视频)
|
||||
|
||||
Reference in New Issue
Block a user