Documentation
¶
Index ¶
- type AccountAttachment
- type ActionSequence
- type AttachmentType
- type BoardPosting
- type CSVList
- type Computer
- type ComputerAttrs
- type ComputerLink
- type ConditionalActionSet
- type Email
- type EmailAttachment
- type ExeColours
- type ExtensionInfo
- type ExtraColours
- type Faction
- type FactionActionSet
- type Goal
- type GoalType
- type Language
- type LinkAttachment
- type MainColours
- type Mission
- type MissionFunctions
- type NextMission
- type NoteAttachment
- type ProjectResource
- type RgbColour
- type Theme
- type ThemeLayout
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccountAttachment ¶
type AccountAttachment struct {
Computer string `xml:"comp,attr" json:"target"`
Username string `xml:"user,attr" json:"username"`
Password string `xml:"pass,attr" json:"password"`
}
func (*AccountAttachment) Type ¶
func (a *AccountAttachment) Type() AttachmentType
type ActionSequence ¶
type AttachmentType ¶
type AttachmentType string
const ( Note AttachmentType = "note" Link AttachmentType = "link" Account AttachmentType = "account" )
type BoardPosting ¶
type CSVList ¶
type CSVList []string
func (CSVList) MarshalXML ¶
MarshalXML custom marshaller to convert []string to CSV string
func (*CSVList) UnmarshalXML ¶
UnmarshalXML custom unmarshaler for a CSV string to []string
type Computer ¶
type Computer struct {
*ComputerAttrs
AdminPass *nodes.AdminPass `xml:"adminPass,omitempty" json:"adminPass,omitempty"`
Accounts []nodes.ComputerAccount `xml:"account" json:"accounts"`
Ports CSVList `xml:"ports" json:"ports"`
PortsForCrack nodes.PortsForCrack `xml:"portsForCrack" json:"portsForCrack"`
Proxy *nodes.ProxyConfig `xml:"proxy,omitempty" json:"proxy"`
Trace *nodes.TraceConfig `xml:"trace,omitempty" json:"trace"`
AdminConfig *nodes.AdminConfig `xml:"admin,omitempty" json:"adminConfig"`
PortRemap nodes.PortRemap `xml:"portRemap,omitempty" json:"portRemap"`
HasTracker nodes.Tracker `xml:"tracker,omitempty" json:"hasTracker"`
PositionNear *nodes.PositionNear `xml:"positionNear,omitempty" json:"positionNear"`
Files []nodes.File `xml:"file" json:"files"`
CustomThemes []nodes.CustomThemeFile `xml:"customthemefile" json:"customThemes"`
EncryptedFiles []nodes.EncryptedFile `xml:"encryptedFile" json:"encryptedFiles"`
Links []ComputerLink `xml:"dlink" json:"links"`
EosLinks []nodes.EosDevice `xml:"eosDevice" json:"eosLinks"`
*ProjectResource
}
type ComputerAttrs ¶
type ComputerAttrs struct {
ID string `xml:"id,attr" json:"id"`
Name string `xml:"name,attr" json:"name"`
IP string `xml:"ip,attr" json:"ip"`
Security int `xml:"security,attr" json:"security"`
AllowsDefaultBootModule bool `xml:"allowsDefaultBootModule,attr" json:"allowsDefaultBootModule"`
Icon nodes.ComputerIcon `xml:"icon,attr" json:"icon"`
Type nodes.ComputerType `xml:"type,attr" json:"type"`
}
type ComputerLink ¶
type ComputerLink struct {
Target string `xml:"target,attr"`
}
type ConditionalActionSet ¶
type ConditionalActionSet struct {
xml.Name `xml:"ConditionalActions" json:"-"`
OnConnect []ActionSequence `xml:"OnConnect,omitempty" json:"onConnect"`
HasFlags []ActionSequence `xml:"HasFlags,omitempty" json:"hasFlags"`
Instantly []ActionSequence `xml:"Instantly,omitempty" json:"instantly"`
OnAdminGained []ActionSequence `xml:"OnAdminGained,omitempty" json:"onAdminGained"`
DoesNotHaveFlags []ActionSequence `xml:"DoesNotHaveFlags,omitempty" json:"doesNotHaveFlags"`
OnDisconnect []ActionSequence `xml:"OnDisconnect,omitempty" json:"onDisconnect"`
*ProjectResource
}
type Email ¶
type Email struct {
Sender string `xml:"sender" json:"sender"`
Subject string `xml:"subject" json:"subject"`
Body string `xml:"body" json:"body"`
Notes []NoteAttachment `xml:"attachments>note"`
Links []LinkAttachment `xml:"attachments>link"`
Accounts []AccountAttachment `xml:"attachments>account"`
}
type EmailAttachment ¶
type EmailAttachment interface {
Type() AttachmentType
}
type ExeColours ¶
type ExtensionInfo ¶
type ExtensionInfo struct {
xml.Name `xml:"HacknetExtension" json:"-"`
Title string `xml:"Name" json:"name"`
AllowSaves bool `json:"allowSaves"`
Language `json:"language"`
StartingNodes CSVList `xml:"StartingVisibleNodes" json:"startingNodes"`
StartingMission ProjectResource `xml:"StartingMission" json:"startingMission"`
StartingActions ProjectResource `xml:"StartingActions" json:"startingActions"`
Description string `xml:"Description" json:"description"`
Factions []ProjectResource `xml:"Faction" json:"factions"`
StartsWithTutorial bool `xml:"StartsWithTutorial" json:"startsWithTutorial"`
HasIntroStartup bool `xml:"HasIntroStartup" json:"hasIntroStartup"`
StartingTheme ProjectResource `xml:"StartingTheme" json:"startingTheme"`
IntroStartupSong string `xml:"IntroStartupSong" json:"introStartupSong"`
}
func (*ExtensionInfo) String ¶
func (ext *ExtensionInfo) String() string
type ExtraColours ¶
type ExtraColours struct {
WarningColor RgbColour `xml:"warningColor"`
SubtleTextColor RgbColour `xml:"subtleTextColor"`
DarkBackgroundColor RgbColour `xml:"darkBackgroundColor"`
IndentBackgroundColor RgbColour `xml:"indentBackgroundColor"`
OutlineColor RgbColour `xml:"outlineColor"`
LockedColor RgbColour `xml:"lockedColor"`
BrightLockedColor RgbColour `xml:"brightLockedColor"`
BrightUnlockedColor RgbColour `xml:"brightUnlockedColor"`
UnlockedColor RgbColour `xml:"unlockedColor"`
LightGray RgbColour `xml:"lightGray"`
ShellColor RgbColour `xml:"shellColor"`
ShellButtonColor RgbColour `xml:"shellButtonColor"`
SemiTransText RgbColour `xml:"semiTransText"`
TerminalTextColor RgbColour `xml:"terminalTextColor"`
TopBarTextColor RgbColour `xml:"topBarTextColor"`
SuperLightWhite RgbColour `xml:"superLightWhite"`
ConnectedNodeHighlight RgbColour `xml:"connectedNodeHighlight"`
NetmapToolTipColor RgbColour `xml:"netmapToolTipColor"`
NetmapToolTipBackground RgbColour `xml:"netmapToolTipBackground"`
TopBarIconsColor RgbColour `xml:"topBarIconsColor"`
ThisComputerNode RgbColour `xml:"thisComputerNode"`
ScanlinesColor RgbColour `xml:"scanlinesColor"`
}
type Faction ¶
type Faction struct {
xml.Name `xml:"CustomFaction"`
ID string `xml:"id,attr"`
FactionName string `xml:"name,attr"`
StartValue int `xml:"playerVal,attr"`
ActionSets []FactionActionSet `xml:"Action"`
*ProjectResource
}
type FactionActionSet ¶
type Goal ¶
type Goal struct {
Type GoalType `xml:"type,attr" json:"type"`
Target *string `xml:"target,attr" json:"target,omitempty"`
DestTarget *string `xml:"destTarget,attr" json:"destTarget,omitempty"`
File *string `xml:"file,attr" json:"file,omitempty"`
Path *string `xml:"path,attr" json:"path,omitempty"`
DestPath *string `xml:"destPath,attr" json:"destPath,omitempty"`
Keyword *string `xml:"keyword,attr" json:"keyword,omitempty"`
Removal *string `xml:"removal,attr" json:"removal,omitempty"`
CaseSensitive *string `xml:"caseSensitive,attr" json:"caseSensitive,omitempty"`
Time *string `xml:"time,attr" json:"time,omitempty"`
Decrypt *bool `xml:"decrypt,attr" json:"decrypt,omitempty"`
DecryptPass *string `xml:"decryptPass,attr" json:"decryptPass,omitempty"`
MailServer *string `xml:"mailServer,attr" json:"mailServer,omitempty"`
Recipient *string `xml:"recipient,attr" json:"recipient,omitempty"`
Subject *string `xml:"subject,attr" json:"subject,omitempty"`
Owner *string `xml:"owner,attr" json:"owner,omitempty"`
}
type GoalType ¶
type GoalType string
const ( FileDeletion GoalType = "filedeletion" ClearFolder GoalType = "clearfolder" FileDownload GoalType = "filedownload" FileChange GoalType = "filechange" GetAdmin GoalType = "getadmin" GetString GoalType = "getstring" Delay GoalType = "delay" HasFlag GoalType = "hasflag" FileUpload GoalType = "fileupload" AddDegree GoalType = "AddDegree" WipeDegrees GoalType = "wipedegrees" SendEmail GoalType = "sendemail" RemoveDeathRowRecord GoalType = "removeDeathRowRecord" ModifyDeathRowRecord GoalType = "modifyDeathRowRecord" GetAdminPass GoalType = "getadminpasswordstring" )
type LinkAttachment ¶
type LinkAttachment struct {
Computer string `xml:"comp,attr" json:"target"`
}
func (*LinkAttachment) Type ¶
func (l *LinkAttachment) Type() AttachmentType
type MainColours ¶
type MainColours struct {
DefaultHighlightColor RgbColour `xml:"defaultHighlightColor"`
DefaultTopBarColor RgbColour `xml:"defaultTopBarColor"`
ModuleColorSolidDefault RgbColour `xml:"moduleColorSolidDefault"`
ModuleColorStrong RgbColour `xml:"moduleColorStrong"`
ModuleColorBacking RgbColour `xml:"moduleColorBacking"`
}
type Mission ¶
type Mission struct {
xml.Name `xml:"mission" json:"-"`
ID string `xml:"id,attr" json:"id"`
ActiveCheck bool `xml:"activeCheck,attr" json:"activeCheck"`
VerifySender bool `xml:"shouldIgnoreSenderVerification,attr" json:"verifySender"`
Goals []Goal `xml:"goals>goal" json:"goals"`
Start MissionFunctions `xml:"missionStart" json:"missionStart"`
End MissionFunctions `xml:"missionEnd" json:"missionEnd"`
NextMission NextMission `xml:"nextMission" json:"nextMission"`
//Branches []ExternalReference[Mission] `xml:"branchMissions>branch" json:"branches"`
Posting *BoardPosting `xml:"posting,omitempty" json:"posting,omitempty"`
Email Email `xml:"email" json:"email"`
*ProjectResource
}
type MissionFunctions ¶
type NextMission ¶
type NextMission struct {
//Path ExternalReference[Mission] `xml:",chardata" json:"path"`
Silent bool `xml:"IsSilent" json:"silent"`
}
type NoteAttachment ¶
type NoteAttachment struct {
Title string `xml:"title,attr" json:"title"`
Content string `xml:",chardata" json:"content"`
}
func (*NoteAttachment) Type ¶
func (n *NoteAttachment) Type() AttachmentType
type ProjectResource ¶
type ProjectResource struct {
Path string `xml:"-" json:"path"`
}
type RgbColour ¶
type RgbColour []int
func (RgbColour) MarshalXML ¶
func (*RgbColour) UnmarshalXML ¶
type Theme ¶
type Theme struct {
XMLName struct{} `xml:"CustomTheme"`
Layout ThemeLayout `xml:"themeLayoutName"`
BackgroundPath string `xml:"backgroundImagePath"`
PreserveScaling bool `xml:"UseAspectPreserveBackgroundScaling"`
BackgroundFill RgbColour `xml:"BackgroundImageFillColor"`
*MainColours
*ExeColours
*ExtraColours
*ProjectResource
}
type ThemeLayout ¶
type ThemeLayout string
const ( Blue ThemeLayout = "blue" Green ThemeLayout = "green" White ThemeLayout = "white" Mint ThemeLayout = "mint" GreenCompact ThemeLayout = "greencompact" RipTide ThemeLayout = "riptide" Colamaeleon ThemeLayout = "colamaeleon" RipTide2 ThemeLayout = "riptide2" )
Source Files
¶
Click to show internal directories.
Click to hide internal directories.