mgr

package
v0.0.0-...-cd5db6d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 23, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const ScanHeight = 3
View Source
const ScanWith = 3

Variables

View Source
var AMgr = &armyMgr{
	armyById:     make(map[int]*model.Army),
	armyByCityId: make(map[int][]*model.Army),
	armyByRId:    make(map[int][]*model.Army),
}
View Source
var GMgr = &generalMgr{
	genByRole: make(map[int][]*model.General),
	genByGId:  make(map[int]*model.General),
}
View Source
var NMMgr = &NationalMapMgr{
	conf:     make(map[int]model.NationalMap),
	sysBuild: make(map[int]model.NationalMap),
}
View Source
var RAttrMgr = &roleAttributeMgr{
	attribute: make(map[int]*model.RoleAttribute),
}
View Source
var RBMgr = &roleBuildMgr{
	dbRB:      make(map[int]*model.MapRoleBuild),
	posRB:     make(map[int]*model.MapRoleBuild),
	roleRB:    make(map[int][]*model.MapRoleBuild),
	giveUpRB:  make(map[int64]map[int]*model.MapRoleBuild),
	destroyRB: make(map[int64]map[int]*model.MapRoleBuild),
}
View Source
var RCMgr = &roleCityMgr{
	dbCity:   make(map[int]*model.MapRoleCity),
	posCity:  make(map[int]*model.MapRoleCity),
	roleCity: make(map[int][]*model.MapRoleCity),
}
View Source
var RFMgr = facilityMgr{
	// contains filtered or unexported fields
}
View Source
var RMgr = &roleMgr{
	roles: make(map[int]*model.Role),
}
View Source
var RResMgr = &roleResMgr{
	rolesRes: make(map[int]*model.RoleRes),
}
View Source
var SkillMgr = &skillMgr{
	skillMap: make(map[int][]*model.Skill),
}
View Source
var UnionMgr = &coalitionMgr{
	unions: make(map[int]*model.Coalition),
}

Functions

func Distance

func Distance(begX, begY, endX, endY int) float64

func GetCityCost

func GetCityCost(cid int) int8

func GetCityLV

func GetCityLV(cid int) int8

func GetDepotCapacity

func GetDepotCapacity(rid int) int

获取仓库容量

func GetMaxDurable

func GetMaxDurable(cid int) int

func GetYield

func GetYield(rid int) model.Yield

获取产量

func RoleNickName

func RoleNickName(rid int) string

func TravelTime

func TravelTime(speed, begX, begY, endX, endY int) int

Types

type NMArray

type NMArray struct {
	// contains filtered or unexported fields
}

type NationalMapMgr

type NationalMapMgr struct {
	// contains filtered or unexported fields
}

func (*NationalMapMgr) IsCanBuild

func (this *NationalMapMgr) IsCanBuild(x, y int) bool

func (*NationalMapMgr) IsCanBuildCity

func (this *NationalMapMgr) IsCanBuildCity(x, y int) bool

func (*NationalMapMgr) Load

func (this *NationalMapMgr) Load()

func (*NationalMapMgr) MapResTypeLevel

func (this *NationalMapMgr) MapResTypeLevel(x, y int) (bool, int8, int8)

func (*NationalMapMgr) PositionBuild

func (this *NationalMapMgr) PositionBuild(x, y int) (model.NationalMap, bool)

func (*NationalMapMgr) Scan

func (this *NationalMapMgr) Scan(x, y int) []model.NationalMap

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL