datamod

package
v0.0.0-...-6b508d1 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2024 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BoardDefaultKey

func BoardDefaultKey() []byte

func BuildingPrototypesDefaultKey

func BuildingPrototypesDefaultKey() []byte

func BuildingsDefaultKey

func BuildingsDefaultKey() []byte

func MetaDefaultKey

func MetaDefaultKey() []byte

func PlayersDefaultKey

func PlayersDefaultKey() []byte

func UnitPrototypesDefaultKey

func UnitPrototypesDefaultKey() []byte

func UnitsDefaultKey

func UnitsDefaultKey() []byte

Types

type Board

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

func NewBoard

func NewBoard(ds lib.Datastore) *Board

func NewBoardFromSlot

func NewBoardFromSlot(dsSlot lib.DatastoreSlot) *Board

func NewBoardWithParent

func NewBoardWithParent(ds lib.Datastore, parent lib.Parent, tableId lib.TableId) *Board

func (*Board) Get

func (m *Board) Get(
	x uint16,
	y uint16,
) *BoardRow

func (*Board) SetFieldCallback

func (m *Board) SetFieldCallback(tableId lib.TableId, rowKey lib.RowKey, columnIndex int, value []byte)

type BoardRow

type BoardRow struct {
	lib.DatastoreStructWithParent
}

func NewBoardRow

func NewBoardRow(dsSlot lib.DatastoreSlot) *BoardRow

func NewBoardRowWithParent

func NewBoardRowWithParent(dsSlot lib.DatastoreSlot, parent lib.Parent, rowKey lib.RowKey) *BoardRow

func (*BoardRow) Get

func (v *BoardRow) Get() (
	landObjectType uint8,
	landPlayerId uint8,
	landObjectId uint8,
	hoverPlayerId uint8,
	hoverUnitId uint8,
	airPlayerId uint8,
	airUnitId uint8,
)

func (*BoardRow) GetAirPlayerId

func (v *BoardRow) GetAirPlayerId() uint8

func (*BoardRow) GetAirUnitId

func (v *BoardRow) GetAirUnitId() uint8

func (*BoardRow) GetHoverPlayerId

func (v *BoardRow) GetHoverPlayerId() uint8

func (*BoardRow) GetHoverUnitId

func (v *BoardRow) GetHoverUnitId() uint8

func (*BoardRow) GetLandObjectId

func (v *BoardRow) GetLandObjectId() uint8

func (*BoardRow) GetLandObjectType

func (v *BoardRow) GetLandObjectType() uint8

func (*BoardRow) GetLandPlayerId

func (v *BoardRow) GetLandPlayerId() uint8

func (*BoardRow) Set

func (v *BoardRow) Set(
	landObjectType uint8,
	landPlayerId uint8,
	landObjectId uint8,
	hoverPlayerId uint8,
	hoverUnitId uint8,
	airPlayerId uint8,
	airUnitId uint8,
)

func (*BoardRow) SetAirPlayerId

func (v *BoardRow) SetAirPlayerId(value uint8)

func (*BoardRow) SetAirUnitId

func (v *BoardRow) SetAirUnitId(value uint8)

func (*BoardRow) SetHoverPlayerId

func (v *BoardRow) SetHoverPlayerId(value uint8)

func (*BoardRow) SetHoverUnitId

func (v *BoardRow) SetHoverUnitId(value uint8)

func (*BoardRow) SetLandObjectId

func (v *BoardRow) SetLandObjectId(value uint8)

func (*BoardRow) SetLandObjectType

func (v *BoardRow) SetLandObjectType(value uint8)

func (*BoardRow) SetLandPlayerId

func (v *BoardRow) SetLandPlayerId(value uint8)

type BuildingPrototypes

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

func NewBuildingPrototypes

func NewBuildingPrototypes(ds lib.Datastore) *BuildingPrototypes

func NewBuildingPrototypesFromSlot

func NewBuildingPrototypesFromSlot(dsSlot lib.DatastoreSlot) *BuildingPrototypes

func NewBuildingPrototypesWithParent

func NewBuildingPrototypesWithParent(ds lib.Datastore, parent lib.Parent, tableId lib.TableId) *BuildingPrototypes

func (*BuildingPrototypes) Get

func (m *BuildingPrototypes) Get(
	buildingType uint8,
) *BuildingPrototypesRow

func (*BuildingPrototypes) SetFieldCallback

func (m *BuildingPrototypes) SetFieldCallback(tableId lib.TableId, rowKey lib.RowKey, columnIndex int, value []byte)

type BuildingPrototypesRow

type BuildingPrototypesRow struct {
	lib.DatastoreStructWithParent
}

func NewBuildingPrototypesRow

func NewBuildingPrototypesRow(dsSlot lib.DatastoreSlot) *BuildingPrototypesRow

func NewBuildingPrototypesRowWithParent

func NewBuildingPrototypesRowWithParent(dsSlot lib.DatastoreSlot, parent lib.Parent, rowKey lib.RowKey) *BuildingPrototypesRow

func (*BuildingPrototypesRow) Get

func (v *BuildingPrototypesRow) Get() (
	width uint8,
	height uint8,
	resourceCost uint16,
	resourceCapacity uint16,
	computeCapacity uint8,
	resourceMine uint8,
	mineTime uint8,
	maxIntegrity uint8,
	buildingTime uint8,
	isArmory bool,
	isEnvironment bool,
)

func (*BuildingPrototypesRow) GetBuildingTime

func (v *BuildingPrototypesRow) GetBuildingTime() uint8

func (*BuildingPrototypesRow) GetComputeCapacity

func (v *BuildingPrototypesRow) GetComputeCapacity() uint8

func (*BuildingPrototypesRow) GetHeight

func (v *BuildingPrototypesRow) GetHeight() uint8

func (*BuildingPrototypesRow) GetIsArmory

func (v *BuildingPrototypesRow) GetIsArmory() bool

func (*BuildingPrototypesRow) GetIsEnvironment

func (v *BuildingPrototypesRow) GetIsEnvironment() bool

func (*BuildingPrototypesRow) GetMaxIntegrity

func (v *BuildingPrototypesRow) GetMaxIntegrity() uint8

func (*BuildingPrototypesRow) GetMineTime

func (v *BuildingPrototypesRow) GetMineTime() uint8

func (*BuildingPrototypesRow) GetResourceCapacity

func (v *BuildingPrototypesRow) GetResourceCapacity() uint16

func (*BuildingPrototypesRow) GetResourceCost

func (v *BuildingPrototypesRow) GetResourceCost() uint16

func (*BuildingPrototypesRow) GetResourceMine

func (v *BuildingPrototypesRow) GetResourceMine() uint8

func (*BuildingPrototypesRow) GetWidth

func (v *BuildingPrototypesRow) GetWidth() uint8

func (*BuildingPrototypesRow) Set

func (v *BuildingPrototypesRow) Set(
	width uint8,
	height uint8,
	resourceCost uint16,
	resourceCapacity uint16,
	computeCapacity uint8,
	resourceMine uint8,
	mineTime uint8,
	maxIntegrity uint8,
	buildingTime uint8,
	isArmory bool,
	isEnvironment bool,
)

func (*BuildingPrototypesRow) SetBuildingTime

func (v *BuildingPrototypesRow) SetBuildingTime(value uint8)

func (*BuildingPrototypesRow) SetComputeCapacity

func (v *BuildingPrototypesRow) SetComputeCapacity(value uint8)

func (*BuildingPrototypesRow) SetHeight

func (v *BuildingPrototypesRow) SetHeight(value uint8)

func (*BuildingPrototypesRow) SetIsArmory

func (v *BuildingPrototypesRow) SetIsArmory(value bool)

func (*BuildingPrototypesRow) SetIsEnvironment

func (v *BuildingPrototypesRow) SetIsEnvironment(value bool)

func (*BuildingPrototypesRow) SetMaxIntegrity

func (v *BuildingPrototypesRow) SetMaxIntegrity(value uint8)

func (*BuildingPrototypesRow) SetMineTime

func (v *BuildingPrototypesRow) SetMineTime(value uint8)

func (*BuildingPrototypesRow) SetResourceCapacity

func (v *BuildingPrototypesRow) SetResourceCapacity(value uint16)

func (*BuildingPrototypesRow) SetResourceCost

func (v *BuildingPrototypesRow) SetResourceCost(value uint16)

func (*BuildingPrototypesRow) SetResourceMine

func (v *BuildingPrototypesRow) SetResourceMine(value uint8)

func (*BuildingPrototypesRow) SetWidth

func (v *BuildingPrototypesRow) SetWidth(value uint8)

type Buildings

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

func NewBuildings

func NewBuildings(ds lib.Datastore) *Buildings

func NewBuildingsFromSlot

func NewBuildingsFromSlot(dsSlot lib.DatastoreSlot) *Buildings

func NewBuildingsWithParent

func NewBuildingsWithParent(ds lib.Datastore, parent lib.Parent, tableId lib.TableId) *Buildings

func (*Buildings) Get

func (m *Buildings) Get(
	playerId uint8,
	buildingId uint8,
) *BuildingsRow

func (*Buildings) SetFieldCallback

func (m *Buildings) SetFieldCallback(tableId lib.TableId, rowKey lib.RowKey, columnIndex int, value []byte)

type BuildingsRow

type BuildingsRow struct {
	lib.DatastoreStructWithParent
}

func NewBuildingsRow

func NewBuildingsRow(dsSlot lib.DatastoreSlot) *BuildingsRow

func NewBuildingsRowWithParent

func NewBuildingsRowWithParent(dsSlot lib.DatastoreSlot, parent lib.Parent, rowKey lib.RowKey) *BuildingsRow

func (*BuildingsRow) Get

func (v *BuildingsRow) Get() (
	x uint16,
	y uint16,
	buildingType uint8,
	state uint8,
	integrity uint8,
	timestamp uint32,
)

func (*BuildingsRow) GetBuildingType

func (v *BuildingsRow) GetBuildingType() uint8

func (*BuildingsRow) GetIntegrity

func (v *BuildingsRow) GetIntegrity() uint8

func (*BuildingsRow) GetState

func (v *BuildingsRow) GetState() uint8

func (*BuildingsRow) GetTimestamp

func (v *BuildingsRow) GetTimestamp() uint32

func (*BuildingsRow) GetX

func (v *BuildingsRow) GetX() uint16

func (*BuildingsRow) GetY

func (v *BuildingsRow) GetY() uint16

func (*BuildingsRow) Set

func (v *BuildingsRow) Set(
	x uint16,
	y uint16,
	buildingType uint8,
	state uint8,
	integrity uint8,
	timestamp uint32,
)

func (*BuildingsRow) SetBuildingType

func (v *BuildingsRow) SetBuildingType(value uint8)

func (*BuildingsRow) SetIntegrity

func (v *BuildingsRow) SetIntegrity(value uint8)

func (*BuildingsRow) SetState

func (v *BuildingsRow) SetState(value uint8)

func (*BuildingsRow) SetTimestamp

func (v *BuildingsRow) SetTimestamp(value uint32)

func (*BuildingsRow) SetX

func (v *BuildingsRow) SetX(value uint16)

func (*BuildingsRow) SetY

func (v *BuildingsRow) SetY(value uint16)

type Meta

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

func NewMeta

func NewMeta(ds lib.Datastore) *Meta

func NewMetaFromSlot

func NewMetaFromSlot(dsSlot lib.DatastoreSlot) *Meta

func NewMetaWithParent

func NewMetaWithParent(ds lib.Datastore, parent lib.Parent, tableId lib.TableId) *Meta

func (*Meta) Get

func (m *Meta) Get() *MetaRow

func (*Meta) SetFieldCallback

func (m *Meta) SetFieldCallback(tableId lib.TableId, rowKey lib.RowKey, columnIndex int, value []byte)

type MetaRow

type MetaRow struct {
	lib.DatastoreStructWithParent
}

func NewMetaRow

func NewMetaRow(dsSlot lib.DatastoreSlot) *MetaRow

func NewMetaRowWithParent

func NewMetaRowWithParent(dsSlot lib.DatastoreSlot, parent lib.Parent, rowKey lib.RowKey) *MetaRow

func (*MetaRow) Get

func (v *MetaRow) Get() (
	boardWidth uint16,
	boardHeight uint16,
	playerCount uint8,
	unitPrototypeCount uint8,
	buildingPrototypeCount uint8,
	isInitialized bool,
	hasStarted bool,
	creationBlockNumber uint32,
)

func (*MetaRow) GetBoardHeight

func (v *MetaRow) GetBoardHeight() uint16

func (*MetaRow) GetBoardWidth

func (v *MetaRow) GetBoardWidth() uint16

func (*MetaRow) GetBuildingPrototypeCount

func (v *MetaRow) GetBuildingPrototypeCount() uint8

func (*MetaRow) GetCreationBlockNumber

func (v *MetaRow) GetCreationBlockNumber() uint32

func (*MetaRow) GetHasStarted

func (v *MetaRow) GetHasStarted() bool

func (*MetaRow) GetIsInitialized

func (v *MetaRow) GetIsInitialized() bool

func (*MetaRow) GetPlayerCount

func (v *MetaRow) GetPlayerCount() uint8

func (*MetaRow) GetUnitPrototypeCount

func (v *MetaRow) GetUnitPrototypeCount() uint8

func (*MetaRow) Set

func (v *MetaRow) Set(
	boardWidth uint16,
	boardHeight uint16,
	playerCount uint8,
	unitPrototypeCount uint8,
	buildingPrototypeCount uint8,
	isInitialized bool,
	hasStarted bool,
	creationBlockNumber uint32,
)

func (*MetaRow) SetBoardHeight

func (v *MetaRow) SetBoardHeight(value uint16)

func (*MetaRow) SetBoardWidth

func (v *MetaRow) SetBoardWidth(value uint16)

func (*MetaRow) SetBuildingPrototypeCount

func (v *MetaRow) SetBuildingPrototypeCount(value uint8)

func (*MetaRow) SetCreationBlockNumber

func (v *MetaRow) SetCreationBlockNumber(value uint32)

func (*MetaRow) SetHasStarted

func (v *MetaRow) SetHasStarted(value bool)

func (*MetaRow) SetIsInitialized

func (v *MetaRow) SetIsInitialized(value bool)

func (*MetaRow) SetPlayerCount

func (v *MetaRow) SetPlayerCount(value uint8)

func (*MetaRow) SetUnitPrototypeCount

func (v *MetaRow) SetUnitPrototypeCount(value uint8)

type Players

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

func NewPlayers

func NewPlayers(ds lib.Datastore) *Players

func NewPlayersFromSlot

func NewPlayersFromSlot(dsSlot lib.DatastoreSlot) *Players

func NewPlayersWithParent

func NewPlayersWithParent(ds lib.Datastore, parent lib.Parent, tableId lib.TableId) *Players

func (*Players) Get

func (m *Players) Get(
	playerId uint8,
) *PlayersRow

func (*Players) SetFieldCallback

func (m *Players) SetFieldCallback(tableId lib.TableId, rowKey lib.RowKey, columnIndex int, value []byte)

type PlayersRow

type PlayersRow struct {
	lib.DatastoreStructWithParent
}

func NewPlayersRow

func NewPlayersRow(dsSlot lib.DatastoreSlot) *PlayersRow

func NewPlayersRowWithParent

func NewPlayersRowWithParent(dsSlot lib.DatastoreSlot, parent lib.Parent, rowKey lib.RowKey) *PlayersRow

func (*PlayersRow) Get

func (v *PlayersRow) Get() (
	spawnAreaX uint16,
	spawnAreaY uint16,
	spawnAreaWidth uint8,
	spawnAreaHeight uint8,
	workerPortX uint16,
	workerPortY uint16,
	curResource uint16,
	maxResource uint16,
	curArmories uint8,
	computeSupply uint8,
	computeDemand uint8,
	unitCount uint8,
	buildingCount uint8,
	buildingPayQueuePointer uint8,
	buildingBuildQueuePointer uint8,
	unitPayQueuePointer uint8,
	unpurgeableUnitCount uint8,
)

func (*PlayersRow) GetBuildingBuildQueuePointer

func (v *PlayersRow) GetBuildingBuildQueuePointer() uint8

func (*PlayersRow) GetBuildingCount

func (v *PlayersRow) GetBuildingCount() uint8

func (*PlayersRow) GetBuildingPayQueuePointer

func (v *PlayersRow) GetBuildingPayQueuePointer() uint8

func (*PlayersRow) GetComputeDemand

func (v *PlayersRow) GetComputeDemand() uint8

func (*PlayersRow) GetComputeSupply

func (v *PlayersRow) GetComputeSupply() uint8

func (*PlayersRow) GetCurArmories

func (v *PlayersRow) GetCurArmories() uint8

func (*PlayersRow) GetCurResource

func (v *PlayersRow) GetCurResource() uint16

func (*PlayersRow) GetMaxResource

func (v *PlayersRow) GetMaxResource() uint16

func (*PlayersRow) GetSpawnAreaHeight

func (v *PlayersRow) GetSpawnAreaHeight() uint8

func (*PlayersRow) GetSpawnAreaWidth

func (v *PlayersRow) GetSpawnAreaWidth() uint8

func (*PlayersRow) GetSpawnAreaX

func (v *PlayersRow) GetSpawnAreaX() uint16

func (*PlayersRow) GetSpawnAreaY

func (v *PlayersRow) GetSpawnAreaY() uint16

func (*PlayersRow) GetUnitCount

func (v *PlayersRow) GetUnitCount() uint8

func (*PlayersRow) GetUnitPayQueuePointer

func (v *PlayersRow) GetUnitPayQueuePointer() uint8

func (*PlayersRow) GetUnpurgeableUnitCount

func (v *PlayersRow) GetUnpurgeableUnitCount() uint8

func (*PlayersRow) GetWorkerPortX

func (v *PlayersRow) GetWorkerPortX() uint16

func (*PlayersRow) GetWorkerPortY

func (v *PlayersRow) GetWorkerPortY() uint16

func (*PlayersRow) Set

func (v *PlayersRow) Set(
	spawnAreaX uint16,
	spawnAreaY uint16,
	spawnAreaWidth uint8,
	spawnAreaHeight uint8,
	workerPortX uint16,
	workerPortY uint16,
	curResource uint16,
	maxResource uint16,
	curArmories uint8,
	computeSupply uint8,
	computeDemand uint8,
	unitCount uint8,
	buildingCount uint8,
	buildingPayQueuePointer uint8,
	buildingBuildQueuePointer uint8,
	unitPayQueuePointer uint8,
	unpurgeableUnitCount uint8,
)

func (*PlayersRow) SetBuildingBuildQueuePointer

func (v *PlayersRow) SetBuildingBuildQueuePointer(value uint8)

func (*PlayersRow) SetBuildingCount

func (v *PlayersRow) SetBuildingCount(value uint8)

func (*PlayersRow) SetBuildingPayQueuePointer

func (v *PlayersRow) SetBuildingPayQueuePointer(value uint8)

func (*PlayersRow) SetComputeDemand

func (v *PlayersRow) SetComputeDemand(value uint8)

func (*PlayersRow) SetComputeSupply

func (v *PlayersRow) SetComputeSupply(value uint8)

func (*PlayersRow) SetCurArmories

func (v *PlayersRow) SetCurArmories(value uint8)

func (*PlayersRow) SetCurResource

func (v *PlayersRow) SetCurResource(value uint16)

func (*PlayersRow) SetMaxResource

func (v *PlayersRow) SetMaxResource(value uint16)

func (*PlayersRow) SetSpawnAreaHeight

func (v *PlayersRow) SetSpawnAreaHeight(value uint8)

func (*PlayersRow) SetSpawnAreaWidth

func (v *PlayersRow) SetSpawnAreaWidth(value uint8)

func (*PlayersRow) SetSpawnAreaX

func (v *PlayersRow) SetSpawnAreaX(value uint16)

func (*PlayersRow) SetSpawnAreaY

func (v *PlayersRow) SetSpawnAreaY(value uint16)

func (*PlayersRow) SetUnitCount

func (v *PlayersRow) SetUnitCount(value uint8)

func (*PlayersRow) SetUnitPayQueuePointer

func (v *PlayersRow) SetUnitPayQueuePointer(value uint8)

func (*PlayersRow) SetUnpurgeableUnitCount

func (v *PlayersRow) SetUnpurgeableUnitCount(value uint8)

func (*PlayersRow) SetWorkerPortX

func (v *PlayersRow) SetWorkerPortX(value uint16)

func (*PlayersRow) SetWorkerPortY

func (v *PlayersRow) SetWorkerPortY(value uint16)

type UnitPrototypes

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

func NewUnitPrototypes

func NewUnitPrototypes(ds lib.Datastore) *UnitPrototypes

func NewUnitPrototypesFromSlot

func NewUnitPrototypesFromSlot(dsSlot lib.DatastoreSlot) *UnitPrototypes

func NewUnitPrototypesWithParent

func NewUnitPrototypesWithParent(ds lib.Datastore, parent lib.Parent, tableId lib.TableId) *UnitPrototypes

func (*UnitPrototypes) Get

func (m *UnitPrototypes) Get(
	unitType uint8,
) *UnitPrototypesRow

func (*UnitPrototypes) SetFieldCallback

func (m *UnitPrototypes) SetFieldCallback(tableId lib.TableId, rowKey lib.RowKey, columnIndex int, value []byte)

type UnitPrototypesRow

type UnitPrototypesRow struct {
	lib.DatastoreStructWithParent
}

func NewUnitPrototypesRow

func NewUnitPrototypesRow(dsSlot lib.DatastoreSlot) *UnitPrototypesRow

func NewUnitPrototypesRowWithParent

func NewUnitPrototypesRowWithParent(dsSlot lib.DatastoreSlot, parent lib.Parent, rowKey lib.RowKey) *UnitPrototypesRow

func (*UnitPrototypesRow) Get

func (v *UnitPrototypesRow) Get() (
	layer uint8,
	resourceCost uint16,
	computeCost uint8,
	spawnTime uint8,
	maxIntegrity uint8,
	landStrength uint8,
	hoverStrength uint8,
	airStrength uint8,
	attackRange uint8,
	attackCooldown uint8,
	isAssault bool,
	isConfrontational bool,
	isWorker bool,
	isPurgeable bool,
)

func (*UnitPrototypesRow) GetAirStrength

func (v *UnitPrototypesRow) GetAirStrength() uint8

func (*UnitPrototypesRow) GetAttackCooldown

func (v *UnitPrototypesRow) GetAttackCooldown() uint8

func (*UnitPrototypesRow) GetAttackRange

func (v *UnitPrototypesRow) GetAttackRange() uint8

func (*UnitPrototypesRow) GetComputeCost

func (v *UnitPrototypesRow) GetComputeCost() uint8

func (*UnitPrototypesRow) GetHoverStrength

func (v *UnitPrototypesRow) GetHoverStrength() uint8

func (*UnitPrototypesRow) GetIsAssault

func (v *UnitPrototypesRow) GetIsAssault() bool

func (*UnitPrototypesRow) GetIsConfrontational

func (v *UnitPrototypesRow) GetIsConfrontational() bool

func (*UnitPrototypesRow) GetIsPurgeable

func (v *UnitPrototypesRow) GetIsPurgeable() bool

func (*UnitPrototypesRow) GetIsWorker

func (v *UnitPrototypesRow) GetIsWorker() bool

func (*UnitPrototypesRow) GetLandStrength

func (v *UnitPrototypesRow) GetLandStrength() uint8

func (*UnitPrototypesRow) GetLayer

func (v *UnitPrototypesRow) GetLayer() uint8

func (*UnitPrototypesRow) GetMaxIntegrity

func (v *UnitPrototypesRow) GetMaxIntegrity() uint8

func (*UnitPrototypesRow) GetResourceCost

func (v *UnitPrototypesRow) GetResourceCost() uint16

func (*UnitPrototypesRow) GetSpawnTime

func (v *UnitPrototypesRow) GetSpawnTime() uint8

func (*UnitPrototypesRow) Set

func (v *UnitPrototypesRow) Set(
	layer uint8,
	resourceCost uint16,
	computeCost uint8,
	spawnTime uint8,
	maxIntegrity uint8,
	landStrength uint8,
	hoverStrength uint8,
	airStrength uint8,
	attackRange uint8,
	attackCooldown uint8,
	isAssault bool,
	isConfrontational bool,
	isWorker bool,
	isPurgeable bool,
)

func (*UnitPrototypesRow) SetAirStrength

func (v *UnitPrototypesRow) SetAirStrength(value uint8)

func (*UnitPrototypesRow) SetAttackCooldown

func (v *UnitPrototypesRow) SetAttackCooldown(value uint8)

func (*UnitPrototypesRow) SetAttackRange

func (v *UnitPrototypesRow) SetAttackRange(value uint8)

func (*UnitPrototypesRow) SetComputeCost

func (v *UnitPrototypesRow) SetComputeCost(value uint8)

func (*UnitPrototypesRow) SetHoverStrength

func (v *UnitPrototypesRow) SetHoverStrength(value uint8)

func (*UnitPrototypesRow) SetIsAssault

func (v *UnitPrototypesRow) SetIsAssault(value bool)

func (*UnitPrototypesRow) SetIsConfrontational

func (v *UnitPrototypesRow) SetIsConfrontational(value bool)

func (*UnitPrototypesRow) SetIsPurgeable

func (v *UnitPrototypesRow) SetIsPurgeable(value bool)

func (*UnitPrototypesRow) SetIsWorker

func (v *UnitPrototypesRow) SetIsWorker(value bool)

func (*UnitPrototypesRow) SetLandStrength

func (v *UnitPrototypesRow) SetLandStrength(value uint8)

func (*UnitPrototypesRow) SetLayer

func (v *UnitPrototypesRow) SetLayer(value uint8)

func (*UnitPrototypesRow) SetMaxIntegrity

func (v *UnitPrototypesRow) SetMaxIntegrity(value uint8)

func (*UnitPrototypesRow) SetResourceCost

func (v *UnitPrototypesRow) SetResourceCost(value uint16)

func (*UnitPrototypesRow) SetSpawnTime

func (v *UnitPrototypesRow) SetSpawnTime(value uint8)

type Units

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

func NewUnits

func NewUnits(ds lib.Datastore) *Units

func NewUnitsFromSlot

func NewUnitsFromSlot(dsSlot lib.DatastoreSlot) *Units

func NewUnitsWithParent

func NewUnitsWithParent(ds lib.Datastore, parent lib.Parent, tableId lib.TableId) *Units

func (*Units) Get

func (m *Units) Get(
	playerId uint8,
	unitId uint8,
) *UnitsRow

func (*Units) SetFieldCallback

func (m *Units) SetFieldCallback(tableId lib.TableId, rowKey lib.RowKey, columnIndex int, value []byte)

type UnitsRow

type UnitsRow struct {
	lib.DatastoreStructWithParent
}

func NewUnitsRow

func NewUnitsRow(dsSlot lib.DatastoreSlot) *UnitsRow

func NewUnitsRowWithParent

func NewUnitsRowWithParent(dsSlot lib.DatastoreSlot, parent lib.Parent, rowKey lib.RowKey) *UnitsRow

func (*UnitsRow) Get

func (v *UnitsRow) Get() (
	x uint16,
	y uint16,
	unitType uint8,
	state uint8,
	load uint8,
	integrity uint8,
	timestamp uint32,
	command uint64,
	commandExtra uint64,
	commandMeta uint8,
	isPreTicked bool,
)

func (*UnitsRow) GetCommand

func (v *UnitsRow) GetCommand() uint64

func (*UnitsRow) GetCommandExtra

func (v *UnitsRow) GetCommandExtra() uint64

func (*UnitsRow) GetCommandMeta

func (v *UnitsRow) GetCommandMeta() uint8

func (*UnitsRow) GetIntegrity

func (v *UnitsRow) GetIntegrity() uint8

func (*UnitsRow) GetIsPreTicked

func (v *UnitsRow) GetIsPreTicked() bool

func (*UnitsRow) GetLoad

func (v *UnitsRow) GetLoad() uint8

func (*UnitsRow) GetState

func (v *UnitsRow) GetState() uint8

func (*UnitsRow) GetTimestamp

func (v *UnitsRow) GetTimestamp() uint32

func (*UnitsRow) GetUnitType

func (v *UnitsRow) GetUnitType() uint8

func (*UnitsRow) GetX

func (v *UnitsRow) GetX() uint16

func (*UnitsRow) GetY

func (v *UnitsRow) GetY() uint16

func (*UnitsRow) Set

func (v *UnitsRow) Set(
	x uint16,
	y uint16,
	unitType uint8,
	state uint8,
	load uint8,
	integrity uint8,
	timestamp uint32,
	command uint64,
	commandExtra uint64,
	commandMeta uint8,
	isPreTicked bool,
)

func (*UnitsRow) SetCommand

func (v *UnitsRow) SetCommand(value uint64)

func (*UnitsRow) SetCommandExtra

func (v *UnitsRow) SetCommandExtra(value uint64)

func (*UnitsRow) SetCommandMeta

func (v *UnitsRow) SetCommandMeta(value uint8)

func (*UnitsRow) SetIntegrity

func (v *UnitsRow) SetIntegrity(value uint8)

func (*UnitsRow) SetIsPreTicked

func (v *UnitsRow) SetIsPreTicked(value bool)

func (*UnitsRow) SetLoad

func (v *UnitsRow) SetLoad(value uint8)

func (*UnitsRow) SetState

func (v *UnitsRow) SetState(value uint8)

func (*UnitsRow) SetTimestamp

func (v *UnitsRow) SetTimestamp(value uint32)

func (*UnitsRow) SetUnitType

func (v *UnitsRow) SetUnitType(value uint8)

func (*UnitsRow) SetX

func (v *UnitsRow) SetX(value uint16)

func (*UnitsRow) SetY

func (v *UnitsRow) SetY(value uint16)

Jump to

Keyboard shortcuts

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