GITLAB

zhangqijia / Pro2DServer

Sign in
  • Sign in
  • Project
  • Files
  • Commits
  • Network
  • Graphs
  • Issues 0
  • Merge Requests 0
  • Wiki
  • Pro2DServer
  • cmd
  • test
  • main.go
  • 495e9142   fix: 增加DisConnectRsp协议。增加测试工具 Browse Code »
    zhangqijia
    2022-05-11 17:22:20 +0800  
main.go 407 Bytes
Edit Raw Blame History
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
package main

import (
	"pro2d/cmd/test/service"
	"pro2d/pb"
	"time"
)

func main() {
	tc := service.NewTestClient()
	if tc == nil {
		return
	}

	tc.Login("1")

	pp := &pb.RoleEndBattleReq{
		ChapterId: 1,
		CarbonId:  1,
		Pass:      true,
	}

	time.Sleep(2 * time.Second)
	for {
		//tc.SendPB(pb.ProtoCode_HeartReq, nil)
		tc.SendPB(pb.ProtoCode_RoleEndBattleReq, pp)
		time.Sleep(5 * time.Second)
	}

}