🐞 fix(gvg): 添加农田重复种植提示
This commit is contained in:
@@ -177,6 +177,7 @@ export class GVGProduceHandler {
|
|||||||
for(let field of fields) {
|
for(let field of fields) {
|
||||||
if(!field) return resResult(STATUS.GVG_FIELD_NOT_FOUND);
|
if(!field) return resResult(STATUS.GVG_FIELD_NOT_FOUND);
|
||||||
if(field.lockRoleId != roleId && field.unlockTime > nowSeconds()) return resResult(STATUS.GVG_FIELD_HAS_LOCKED);
|
if(field.lockRoleId != roleId && field.unlockTime > nowSeconds()) return resResult(STATUS.GVG_FIELD_HAS_LOCKED);
|
||||||
|
if(field.lockRoleId == roleId && field.harvestTime > 0) return resResult(STATUS.GVG_FIELD_HAS_PLANT);
|
||||||
}
|
}
|
||||||
|
|
||||||
const cities = await getGVGCities(myLeague);
|
const cities = await getGVGCities(myLeague);
|
||||||
|
|||||||
@@ -343,6 +343,7 @@ export const STATUS = {
|
|||||||
GVG_RESET_TEAM_LOC_FAILED: { code: 21337, simStr: '切换队伍城池失败' },
|
GVG_RESET_TEAM_LOC_FAILED: { code: 21337, simStr: '切换队伍城池失败' },
|
||||||
GVG_USER_NOT_IN_CITY: { code: 21338, simStr: '您不在该城池中' },
|
GVG_USER_NOT_IN_CITY: { code: 21338, simStr: '您不在该城池中' },
|
||||||
GVG_NOT_BATTLE_PERIOD: { code: 21339, simStr: '您只能在激战期进行此操作' },
|
GVG_NOT_BATTLE_PERIOD: { code: 21339, simStr: '您只能在激战期进行此操作' },
|
||||||
|
GVG_FIELD_HAS_PLANT: { code: 21340, simStr: '该田已种植' },
|
||||||
|
|
||||||
// GVG征战中原
|
// GVG征战中原
|
||||||
GVG_VESTIGE_ERR: { code: 21350, simStr: '今日未开放该遗迹' },
|
GVG_VESTIGE_ERR: { code: 21350, simStr: '今日未开放该遗迹' },
|
||||||
|
|||||||
Reference in New Issue
Block a user