protocol

package
v2.0.3 Latest Latest
Warning

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

Go to latest
Published: May 19, 2024 License: AGPL-3.0 Imports: 8 Imported by: 0

Documentation

Overview

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Package protocol implements the DataStorePokemonBank protocol

Index

Constants

View Source
const (
	// ProtocolID is the Protocol ID for the DataStore (Pokemon Bank) protocol
	ProtocolID = 0x73

	// MethodPrepareUploadPokemon is the method ID for the PrepareUploadPokemon method
	MethodPrepareUploadPokemon = 0x28

	// MethodUploadPokemon is the method ID for the UploadPokemon method
	MethodUploadPokemon = 0x29

	// MethodSearchPokemon is the method ID for the SearchPokemon method
	MethodSearchPokemon = 0x2A

	// MethodPrepareTradePokemon is the method ID for the PrepareTradePokemon method
	MethodPrepareTradePokemon = 0x2B

	// MethodTradePokemon is the method ID for the TradePokemon method
	MethodTradePokemon = 0x2C

	// MethodDownloadOtherPokemon is the method ID for the DownloadOtherPokemon method
	MethodDownloadOtherPokemon = 0x2D

	// MethodDownloadMyPokemon is the method ID for the DownloadMyPokemon method
	MethodDownloadMyPokemon = 0x2E

	// MethodDeletePokemon is the method ID for the DeletePokemon method
	MethodDeletePokemon = 0x2F

	// MethodGetTransactionParam is the method ID for the GetTransactionParam method
	MethodGetTransactionParam = 0x30

	// MethodPreparePostBankObject is the method ID for the PreparePostBankObject method
	MethodPreparePostBankObject = 0x31

	// MethodCompletePostBankObject is the method ID for the CompletePostBankObject method
	MethodCompletePostBankObject = 0x32

	// MethodPrepareGetBankObject is the method ID for the PrepareGetBankObject method
	MethodPrepareGetBankObject = 0x33

	// MethodPrepareUpdateBankObject is the method ID for the PrepareUpdateBankObject method
	MethodPrepareUpdateBankObject = 0x34

	// MethodCompleteUpdateBankObject is the method ID for the CompleteUpdateBankObject method
	MethodCompleteUpdateBankObject = 0x35

	// MethodRollbackBankObject is the method ID for the RollbackBankObject method
	MethodRollbackBankObject = 0x36

	// MethodGetUnlockKey is the method ID for the GetUnlockKey method
	MethodGetUnlockKey = 0x37

	// MethodRequestMigration is the method ID for the RequestMigration method
	MethodRequestMigration = 0x38
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Protocol

type Protocol struct {
	PrepareUploadPokemon     func(err error, packet nex.PacketInterface, callID uint32) (*nex.RMCMessage, *nex.Error)
	UploadPokemon            func(err error, packet nex.PacketInterface, callID uint32, param *datastore_pokemon_bank_types.GlobalTradeStationUploadPokemonParam) (*nex.RMCMessage, *nex.Error)
	SearchPokemon            func(err error, packet nex.PacketInterface, callID uint32, param *datastore_pokemon_bank_types.GlobalTradeStationSearchPokemonParam) (*nex.RMCMessage, *nex.Error)
	PrepareTradePokemon      func(err error, packet nex.PacketInterface, callID uint32, param *datastore_pokemon_bank_types.GlobalTradeStationPrepareTradePokemonParam) (*nex.RMCMessage, *nex.Error)
	TradePokemon             func(err error, packet nex.PacketInterface, callID uint32, param *datastore_pokemon_bank_types.GlobalTradeStationTradePokemonParam) (*nex.RMCMessage, *nex.Error)
	DownloadOtherPokemon     func(err error, packet nex.PacketInterface, callID uint32, param *datastore_pokemon_bank_types.GlobalTradeStationDownloadOtherPokemonParam) (*nex.RMCMessage, *nex.Error)
	DownloadMyPokemon        func(err error, packet nex.PacketInterface, callID uint32, param *datastore_pokemon_bank_types.GlobalTradeStationDownloadMyPokemonParam) (*nex.RMCMessage, *nex.Error)
	DeletePokemon            func(err error, packet nex.PacketInterface, callID uint32, param *datastore_pokemon_bank_types.GlobalTradeStationDeletePokemonParam) (*nex.RMCMessage, *nex.Error)
	GetTransactionParam      func(err error, packet nex.PacketInterface, callID uint32, slotID *types.PrimitiveU16) (*nex.RMCMessage, *nex.Error)
	PreparePostBankObject    func(err error, packet nex.PacketInterface, callID uint32, slotID *types.PrimitiveU16, size *types.PrimitiveU32) (*nex.RMCMessage, *nex.Error)
	CompletePostBankObject   func(err error, packet nex.PacketInterface, callID uint32, param *datastore_types.DataStoreCompletePostParam) (*nex.RMCMessage, *nex.Error)
	PrepareGetBankObject     func(err error, packet nex.PacketInterface, callID uint32, slotID *types.PrimitiveU16, applicationID *types.PrimitiveU16) (*nex.RMCMessage, *nex.Error)
	PrepareUpdateBankObject  func(err error, packet nex.PacketInterface, callID uint32, transactionParam *datastore_pokemon_bank_types.BankTransactionParam) (*nex.RMCMessage, *nex.Error)
	CompleteUpdateBankObject func(err error, packet nex.PacketInterface, callID uint32, slotID *types.PrimitiveU16, transactionParam *datastore_pokemon_bank_types.BankTransactionParam, isForce *types.PrimitiveBool) (*nex.RMCMessage, *nex.Error)
	RollbackBankObject       func(err error, packet nex.PacketInterface, callID uint32, slotID *types.PrimitiveU16, transactionParam *datastore_pokemon_bank_types.BankTransactionParam, isForce *types.PrimitiveBool) (*nex.RMCMessage, *nex.Error)
	GetUnlockKey             func(err error, packet nex.PacketInterface, callID uint32, challengeValue *types.PrimitiveU32) (*nex.RMCMessage, *nex.Error)
	RequestMigration         func(err error, packet nex.PacketInterface, callID uint32, oneTimePassword *types.String, boxes *types.List[*types.PrimitiveU32]) (*nex.RMCMessage, *nex.Error)
	// contains filtered or unexported fields
}

Protocol stores all the RMC method handlers for the DataStore (Pokemon Bank) protocol and listens for requests Embeds the DataStore protocol

func NewProtocol

func NewProtocol(endpoint nex.EndpointInterface) *Protocol

NewProtocol returns a new DataStorePokemonBank protocol

func (*Protocol) HandlePacket

func (protocol *Protocol) HandlePacket(packet nex.PacketInterface)

HandlePacket sends the packet to the correct RMC method handler

Directories

Path Synopsis
Package types implements all the types used by the DataStore protocol
Package types implements all the types used by the DataStore protocol

Jump to

Keyboard shortcuts

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