mudopts

package module
v0.0.0-...-2f1000c Latest Latest
Warning

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

Go to latest
Published: Dec 27, 2024 License: MIT Imports: 11 Imported by: 1

README

mudopts

Implementations of the most commonly-used MUD telnet options

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClientCaps

type ClientCaps uint64
const (
	ANSI ClientCaps = 1 << iota
	VT100
	UTF8
	Colors256
	MouseTracking
	OscColorPalette
	ScreenReader
	Proxy
	TrueColor
	MNES
	MSLP
	SSL
)

type ClientInfo

type ClientInfo struct {
	Name    string
	Version string

	Charset   string
	IPAddress string
	TermType  string

	Capabilities ClientCaps
}

func (*ClientInfo) RegisterMNES

func (i *ClientInfo) RegisterMNES(usage telnet.TelOptUsage) telnet.TelnetOption

func (ClientInfo) RegisterMTTS

func (i ClientInfo) RegisterMTTS(usage telnet.TelOptUsage) telnet.TelnetOption

type MCCP2

type MCCP2 struct {
	telopts.BaseTelOpt
	// contains filtered or unexported fields
}

func RegisterMCCP2

func RegisterMCCP2(usage telnet.TelOptUsage) *MCCP2

func (*MCCP2) CompressionActive

func (m *MCCP2) CompressionActive() bool

func (*MCCP2) Subnegotiate

func (m *MCCP2) Subnegotiate(subnegotiation []byte) error

func (*MCCP2) SubnegotiationString

func (m *MCCP2) SubnegotiationString(subnegotiation []byte) (string, error)

func (*MCCP2) TransitionLocalState

func (m *MCCP2) TransitionLocalState(newState telnet.TelOptState) (func() error, error)

func (*MCCP2) TransitionRemoteState

func (m *MCCP2) TransitionRemoteState(newState telnet.TelOptState) (func() error, error)

type MCCP3

type MCCP3 struct {
	telopts.BaseTelOpt
	// contains filtered or unexported fields
}

func RegisterMCCP3

func RegisterMCCP3(usage telnet.TelOptUsage) *MCCP3

func (*MCCP3) Subnegotiate

func (m *MCCP3) Subnegotiate(subnegotiation []byte) error

func (*MCCP3) SubnegotiationString

func (m *MCCP3) SubnegotiationString(subnegotiation []byte) (string, error)

func (*MCCP3) TransitionLocalState

func (m *MCCP3) TransitionLocalState(newState telnet.TelOptState) (func() error, error)

func (*MCCP3) TransitionRemoteState

func (m *MCCP3) TransitionRemoteState(newState telnet.TelOptState) (func() error, error)

type MCCPCompressionStatusEvent

type MCCPCompressionStatusEvent struct {
	telopts.BaseTelOptEvent
	Started bool
	Sending bool
}

func (MCCPCompressionStatusEvent) String

type MSSP

type MSSP struct {
	telopts.BaseTelOpt
	// contains filtered or unexported fields
}

func RegisterMSSP

func RegisterMSSP(usage telnet.TelOptUsage, data MSSPData) *MSSP

func (*MSSP) Data

func (m *MSSP) Data() MSSPData

func (*MSSP) Subnegotiate

func (m *MSSP) Subnegotiate(subnegotiation []byte) error

func (*MSSP) SubnegotiationString

func (m *MSSP) SubnegotiationString(subnegotiation []byte) (string, error)

func (*MSSP) TransitionLocalState

func (m *MSSP) TransitionLocalState(newState telnet.TelOptState) (func() error, error)

type MSSPData

type MSSPData struct {
	Name    string
	Players int
	Uptime  time.Time

	Charset    []string
	Codebase   []string
	Contact    string
	CrawlDelay int
	Created    int
	DiscordURL *url.URL
	Hostname   string
	Icon       *url.URL
	IP         string
	IPV6       string
	Language   string
	Location   string
	MinimumAge int
	Port       []int
	Referral   []string
	SSLPort    int
	Website    *url.URL

	Family     []string
	Genre      string
	Gameplay   string
	Status     string
	GameSystem string
	InterMUD   []string
	Subgenre   string

	Areas     int
	HelpFiles int
	Mobiles   int
	Objects   int
	Rooms     int
	Classes   int
	Levels    int
	Races     int
	Skills    int

	ANSI           bool
	UTF8           bool
	VT100          bool
	XTerm256Color  bool
	XTermTrueColor bool

	PayToPlay   bool
	PayForPerks bool

	HiringBuilders bool
	HiringCoders   bool
}

type MSSPUpdatedEvent

type MSSPUpdatedEvent struct {
	telopts.BaseTelOptEvent

	Data MSSPData
}

func (MSSPUpdatedEvent) String

func (e MSSPUpdatedEvent) String() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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