上传战斗协议
This commit is contained in:
parent
8c8c670279
commit
c852f93d64
@ -30,6 +30,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.AcademyChallen
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
if errdata, record = this.module.battle.CreateEveBattle(session, &pb.BattleEVEReq{
|
if errdata, record = this.module.battle.CreateEveBattle(session, &pb.BattleEVEReq{
|
||||||
|
Rulesid: level.Battleready,
|
||||||
Ptype: pb.PlayType_academy,
|
Ptype: pb.PlayType_academy,
|
||||||
Format: nil,
|
Format: nil,
|
||||||
Sysformat: level.UsFormatList,
|
Sysformat: level.UsFormatList,
|
||||||
|
@ -32,6 +32,7 @@ func (this *apiComp) Teaching(session comm.IUserSession, req *pb.AcademyTeaching
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
if errdata, record = this.module.battle.CreateEveBattle(session, &pb.BattleEVEReq{
|
if errdata, record = this.module.battle.CreateEveBattle(session, &pb.BattleEVEReq{
|
||||||
|
Rulesid: level.Battleready,
|
||||||
Ptype: pb.PlayType_heroteaching,
|
Ptype: pb.PlayType_heroteaching,
|
||||||
Format: nil,
|
Format: nil,
|
||||||
Sysformat: level.UsFormatList,
|
Sysformat: level.UsFormatList,
|
||||||
|
@ -116,6 +116,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.ArenaChallenge
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
if errdata, record = this.module.battle.CreatePvpBattle(session, &pb.BattlePVPReq{
|
if errdata, record = this.module.battle.CreatePvpBattle(session, &pb.BattlePVPReq{
|
||||||
|
Rulesid: 105,
|
||||||
Ptype: pb.PlayType_arena,
|
Ptype: pb.PlayType_arena,
|
||||||
Redformat: &pb.PVPFormation{Uid: red.Uid, Leadpos: red.Attack.Leadpos, Format: red.Attack.Formt},
|
Redformat: &pb.PVPFormation{Uid: red.Uid, Leadpos: red.Attack.Leadpos, Format: red.Attack.Formt},
|
||||||
Buleformat: &pb.PVPFormation{Uid: bule.Uid, Leadpos: bule.Defend.Leadpos, Format: bule.Defend.Formt},
|
Buleformat: &pb.PVPFormation{Uid: bule.Uid, Leadpos: bule.Defend.Leadpos, Format: bule.Defend.Formt},
|
||||||
|
@ -59,6 +59,7 @@ func (this *apiComp) Plot(session comm.IUserSession, req *pb.ArenaPlotReq) (errd
|
|||||||
index = ndata.Index
|
index = ndata.Index
|
||||||
}
|
}
|
||||||
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: npc.BattleReadyID,
|
||||||
Ptype: pb.PlayType_arena,
|
Ptype: pb.PlayType_arena,
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
Mformat: []int32{npc.MonsterformatId[index]},
|
Mformat: []int32{npc.MonsterformatId[index]},
|
||||||
|
@ -32,6 +32,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.CombatChalleng
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: manster.BattleReadyID,
|
||||||
Ptype: pb.PlayType_combat,
|
Ptype: pb.PlayType_combat,
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
Mformat: manster.FormatList,
|
Mformat: manster.FormatList,
|
||||||
|
@ -70,6 +70,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.EnchantChallen
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: battleconf.BattleReadyID,
|
||||||
Ptype: pb.PlayType_enchant,
|
Ptype: pb.PlayType_enchant,
|
||||||
Title: "",
|
Title: "",
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
|
@ -69,6 +69,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.GuildGveChalle
|
|||||||
// }
|
// }
|
||||||
|
|
||||||
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: conf.BattleReadyID,
|
||||||
Ptype: pb.PlayType_moonfantasy,
|
Ptype: pb.PlayType_moonfantasy,
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
Mformat: conf.Boss,
|
Mformat: conf.Boss,
|
||||||
|
@ -101,6 +101,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.HuntingChallen
|
|||||||
}
|
}
|
||||||
|
|
||||||
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: cfgData.BattleReadyID,
|
||||||
Ptype: pb.PlayType_hunting,
|
Ptype: pb.PlayType_hunting,
|
||||||
Title: "",
|
Title: "",
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
|
@ -78,6 +78,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.MainlineChalle
|
|||||||
}
|
}
|
||||||
|
|
||||||
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: conf.BattleReadyID,
|
||||||
Ptype: pb.PlayType_mainline,
|
Ptype: pb.PlayType_mainline,
|
||||||
Title: "",
|
Title: "",
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
|
@ -118,6 +118,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.MlineChallenge
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: stageConf.BattleReadyID,
|
||||||
Ptype: pb.PlayType_mainline,
|
Ptype: pb.PlayType_mainline,
|
||||||
Title: "",
|
Title: "",
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
|
@ -107,6 +107,7 @@ func (this *apiComp) Battle(session comm.IUserSession, req *pb.MoonfantasyBattle
|
|||||||
}
|
}
|
||||||
|
|
||||||
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: boss.BattleReadyID,
|
||||||
Ptype: pb.PlayType_moonfantasy,
|
Ptype: pb.PlayType_moonfantasy,
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
Mformat: boss.Monsterformatid,
|
Mformat: boss.Monsterformatid,
|
||||||
|
@ -77,6 +77,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.PagodaChalleng
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: conf.BattleReadyID,
|
||||||
Ptype: pb.PlayType_pagoda,
|
Ptype: pb.PlayType_pagoda,
|
||||||
Title: "",
|
Title: "",
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
|
@ -114,6 +114,7 @@ func (this *apiComp) ChallengeRace(session comm.IUserSession, req *pb.PagodaChal
|
|||||||
pType = pb.PlayType_race
|
pType = pb.PlayType_race
|
||||||
}
|
}
|
||||||
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: conf.BattlereadyID,
|
||||||
Ptype: pType,
|
Ptype: pType,
|
||||||
Title: "",
|
Title: "",
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
|
@ -28,6 +28,7 @@ func (this *apiComp) NPCBattkle(session comm.IUserSession, req *pb.PracticeNPCBa
|
|||||||
}
|
}
|
||||||
|
|
||||||
if errdata, record = this.module.battle.CreateLPVEBattle(session, &pb.BattleLPVEReq{
|
if errdata, record = this.module.battle.CreateLPVEBattle(session, &pb.BattleLPVEReq{
|
||||||
|
Rulesid: 111,
|
||||||
Ptype: pb.PlayType_practicenpc,
|
Ptype: pb.PlayType_practicenpc,
|
||||||
Format: req.Formation,
|
Format: req.Formation,
|
||||||
Monsterleadpos: room.Captain,
|
Monsterleadpos: room.Captain,
|
||||||
|
@ -309,6 +309,7 @@ func (this *Pvp) startBattle(battle *BattleItem) {
|
|||||||
err error
|
err error
|
||||||
)
|
)
|
||||||
if errdata, record = this.battle.CreateRtPvpBattle(&pb.BattleRTPVPReq{
|
if errdata, record = this.battle.CreateRtPvpBattle(&pb.BattleRTPVPReq{
|
||||||
|
Rulesid: 111,
|
||||||
Ptype: pb.PlayType_friendsmeet,
|
Ptype: pb.PlayType_friendsmeet,
|
||||||
Title: "",
|
Title: "",
|
||||||
RedCompId: battle.Red.Uid,
|
RedCompId: battle.Red.Uid,
|
||||||
|
@ -97,6 +97,7 @@ func (this *apiComp) Challenge(session comm.IUserSession, req *pb.VikingChalleng
|
|||||||
}
|
}
|
||||||
|
|
||||||
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
errdata, record := this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: cfgData.BattleReadyID,
|
||||||
Ptype: pb.PlayType_viking,
|
Ptype: pb.PlayType_viking,
|
||||||
Title: "",
|
Title: "",
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
|
@ -53,6 +53,7 @@ func (this *apiComp) Battlestart(session comm.IUserSession, req *pb.WorldtaskBat
|
|||||||
record *pb.DBBattleRecord
|
record *pb.DBBattleRecord
|
||||||
)
|
)
|
||||||
errdata, record = b.CreateEveBattle(session, &pb.BattleEVEReq{
|
errdata, record = b.CreateEveBattle(session, &pb.BattleEVEReq{
|
||||||
|
Rulesid: battleConf.BattleReadyID,
|
||||||
Ptype: pb.PlayType_rtask,
|
Ptype: pb.PlayType_rtask,
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
Buleformat: battleConf.FormatList,
|
Buleformat: battleConf.FormatList,
|
||||||
|
@ -41,6 +41,7 @@ func (this *apiComp) BattleStart(session comm.IUserSession, req *pb.WTaskBattleS
|
|||||||
}
|
}
|
||||||
|
|
||||||
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
if errdata, record = this.module.battle.CreatePveBattle(session, &pb.BattlePVEReq{
|
||||||
|
Rulesid: battleConf.BattleReadyID,
|
||||||
Ptype: pb.PlayType_moonfantasy,
|
Ptype: pb.PlayType_moonfantasy,
|
||||||
Format: req.Battle,
|
Format: req.Battle,
|
||||||
Mformat: battleConf.FormatList,
|
Mformat: battleConf.FormatList,
|
||||||
|
Loading…
Reference in New Issue
Block a user