Skip to content

Latest commit

 

History

History
2841 lines (1632 loc) · 55.1 KB

Backend_GameLogic_GameUIManager.default.md

File metadata and controls

2841 lines (1632 loc) · 55.1 KB

Class: default

Backend/GameLogic/GameUIManager.default

Hierarchy

  • EventEmitter

    default

Table of contents

Constructors

Properties

Accessors

Methods

Constructors

constructor

Private new default(gameManager, terminalHandle)

Parameters

Name Type
gameManager default
terminalHandle MutableRefObject<undefined | TerminalHandle>

Overrides

EventEmitter.constructor

Properties

abandoning

Private abandoning: boolean = false


artifactSending

Private artifactSending: Object = {}

Index signature

▪ [key: string]: Artifact | undefined


extraMinerLocations

Private extraMinerLocations: WorldCoords[] = []


forcesSending

Private forcesSending: Object = {}

Index signature

▪ [key: string]: number


gameManager

Private Readonly gameManager: default


hoverArtifact$

Readonly hoverArtifact$: Monomitter<undefined | Artifact>


hoverArtifactId$

Readonly hoverArtifactId$: Monomitter<undefined | ArtifactId>


hoverPlanet$

Readonly hoverPlanet$: Monomitter<undefined | Planet>


hoverPlanetId$

Readonly hoverPlanetId$: Monomitter<undefined | LocationId>


isAbandoning$

Readonly isAbandoning$: Monomitter<boolean>


isChoosingTargetPlanet

Private isChoosingTargetPlanet: boolean = false

The Wormhole artifact requires you to choose a target planet. This value indicates whether or not the player is currently selecting a target planet.


isSending

Private isSending: boolean = false


isSending$

Readonly isSending$: Monomitter<boolean>


minerLocation

Private minerLocation: undefined | WorldCoords


modalManager

Private modalManager: default


mouseDownOverCoords

Private mouseDownOverCoords: undefined | WorldCoords


mouseDownOverPlanet

Private mouseDownOverPlanet: undefined | LocatablePlanet


mouseHoveringOverCoords

Private mouseHoveringOverCoords: undefined | WorldCoords


mouseHoveringOverPlanet

Private mouseHoveringOverPlanet: undefined | LocatablePlanet


myArtifacts$

Readonly myArtifacts$: Monomitter<Map<ArtifactId, Artifact>>


onChooseTargetPlanet

Private Optional onChooseTargetPlanet: (planet: undefined | LocatablePlanet) => void

Type declaration

▸ (planet): void

Parameters
Name Type
planet undefined | LocatablePlanet
Returns

void


overlayContainer

Private Optional overlayContainer: HTMLDivElement

In order to render React on top of the game, we need to insert React nodes into an overlay container. We keep a reference to this container, so that our React components can optionally choose to render themselves into this overlay container using React Portals.


planetHoveringInRenderer

Private planetHoveringInRenderer: boolean = false


plugins

Private plugins: PluginManager


previousSelectedPlanetId

Private previousSelectedPlanetId: undefined | LocationId


radiusMap

Private Readonly radiusMap: Object

Index signature

▪ [PlanetLevel: number]: number


selectedCoords

Private selectedCoords: undefined | WorldCoords


selectedPlanetId

Private selectedPlanetId: undefined | LocationId


selectedPlanetId$

Readonly selectedPlanetId$: Monomitter<undefined | LocationId>


sendingCoords

Private sendingCoords: undefined | WorldCoords


sendingPlanet

Private sendingPlanet: undefined | LocatablePlanet


silverSending

Private silverSending: Object = {}

Index signature

▪ [key: string]: number


terminal

Private terminal: MutableRefObject<undefined | TerminalHandle>


viewportEntities

Private viewportEntities: ViewportEntities

Accessors

captureZonesEnabled

get captureZonesEnabled(): boolean

Returns

boolean


contractConstants

get contractConstants(): ContractConstants

Returns

ContractConstants

Methods

activateArtifact

activateArtifact(locationId, id, wormholeTo?): void

Parameters

Name Type
locationId LocationId
id ArtifactId
wormholeTo? LocationId

Returns

void


addAccount

addAccount(coords): Promise<boolean>

Parameters

Name Type
coords WorldCoords

Returns

Promise<boolean>


addNewChunk

addNewChunk(chunk): void

Parameters

Name Type
chunk Chunk

Returns

void


bulkAddNewChunks

bulkAddNewChunks(chunks): Promise<void>

Parameters

Name Type
chunks Chunk[]

Returns

Promise<void>


buyHat

buyHat(planet): void

Parameters

Name Type
planet Planet

Returns

void


centerCoords

centerCoords(coords): void

Parameters

Name Type
coords WorldCoords

Returns

void


centerLocationId

centerLocationId(planetId): void

Parameters

Name Type
planetId LocationId

Returns

void


centerPlanet

centerPlanet(planet): void

Parameters

Name Type
planet undefined | LocatablePlanet

Returns

void


deactivateArtifact

deactivateArtifact(locationId, artifactId): void

Parameters

Name Type
locationId LocationId
artifactId ArtifactId

Returns

void


depositArtifact

depositArtifact(locationId, artifactId): void

Parameters

Name Type
locationId LocationId
artifactId ArtifactId

Returns

void


destroy

destroy(): void

Returns

void


disableCustomRenderer

disableCustomRenderer(customRenderer): void

This function will remove the passed in renderer from the renderering stack. If the renderer is on top of the renderering stack the next renderer will be the one bellow it.

Parameters

Name Type Description
customRenderer BaseRenderer a Renderer that follows one of the 23 renderer tempaltes

Returns

void


disconnectTwitter

disconnectTwitter(twitter): Promise<void>

Parameters

Name Type
twitter string

Returns

Promise<void>


discoverBiome

discoverBiome(planet): void

Parameters

Name Type
planet LocatablePlanet

Returns

void


drawAllRunningPlugins

drawAllRunningPlugins(ctx): void

Parameters

Name Type
ctx CanvasRenderingContext2D

Returns

void


findArtifact

findArtifact(planetId): void

Parameters

Name Type
planetId LocationId

Returns

void


generateVerificationTweet

generateVerificationTweet(twitter): Promise<string>

Parameters

Name Type
twitter string

Returns

Promise<string>


get2dRenderer

get2dRenderer(): null | CanvasRenderingContext2D

Returns

null | CanvasRenderingContext2D

the CanvasRenderingContext2D for the game canvas.


getAbandonRangeChangePercent

getAbandonRangeChangePercent(): number

Returns

number


getAbandonSpeedChangePercent

getAbandonSpeedChangePercent(): number

Returns

number


getAccount

getAccount(): undefined | EthAddress

Returns

undefined | EthAddress


getAllMinerLocations

getAllMinerLocations(): WorldCoords[]

Returns

WorldCoords[]


getAllOwnedPlanets

getAllOwnedPlanets(): Planet[]

Returns

Planet[]


getAllPlayers

getAllPlayers(): Player[]

Returns

Player[]


getAllVoyages

getAllVoyages(): QueuedArrival[]

Returns

QueuedArrival[]


getArtifactMap

getArtifactMap(): Map<ArtifactId, Artifact>

Returns

Map<ArtifactId, Artifact>


getArtifactPlanet

getArtifactPlanet(artifact): undefined | Planet

Parameters

Name Type
artifact Artifact

Returns

undefined | Planet


getArtifactPointValues

getArtifactPointValues(): ArtifactPointValues

Returns

ArtifactPointValues


getArtifactSending

getArtifactSending(planetId?): undefined | Artifact

Parameters

Name Type
planetId? LocationId

Returns

undefined | Artifact


getArtifactUpdated$

getArtifactUpdated$(): Monomitter<ArtifactId>

Returns

Monomitter<ArtifactId>


getArtifactWithId

getArtifactWithId(artifactId): undefined | Artifact

Parameters

Name Type
artifactId undefined | ArtifactId

Returns

undefined | Artifact


getArtifactsWithIds

getArtifactsWithIds(artifactIds?): (undefined | Artifact)[]

Parameters

Name Type
artifactIds? ArtifactId[]

Returns

(undefined | Artifact)[]


getBiomeKey

Private getBiomeKey(biome): string

Parameters

Name Type
biome Biome

Returns

string


getBiomePerlin

getBiomePerlin(coords, floor): number

Parameters

Name Type
coords WorldCoords
floor boolean

Returns

number


getBooleanSetting

getBooleanSetting(setting): boolean

Parameters

Name Type
setting Setting

Returns

boolean


getCaptureZoneGenerator

getCaptureZoneGenerator(): undefined | CaptureZoneGenerator

Returns

undefined | CaptureZoneGenerator


getCaptureZonePointValues

getCaptureZonePointValues(): [number, number, number, number, number, number, number, number, number, number]

Returns

[number, number, number, number, number, number, number, number, number, number]


getCaptureZones

getCaptureZones(): Set<CaptureZone>

Returns

Set<CaptureZone>


getChunk

getChunk(chunkFootprint): undefined | Chunk

Parameters

Name Type
chunkFootprint Rectangle

Returns

undefined | Chunk


getContractAddress

getContractAddress(): EthAddress

Returns

EthAddress


getDefaultSpaceJunkForPlanetLevel

getDefaultSpaceJunkForPlanetLevel(level): number

Parameters

Name Type
level number

Returns

number


getDiagnostics

getDiagnostics(): Diagnostics

Returns

Diagnostics


getDiscoverBiomeName

getDiscoverBiomeName(biome): string

Parameters

Name Type
biome Biome

Returns

string


getDistCoords

getDistCoords(from, to): number

Parameters

Name Type
from WorldCoords
to WorldCoords

Returns

number


getEndTimeSeconds

getEndTimeSeconds(): number

Returns

number


getEnergyArrivingForMove

getEnergyArrivingForMove(from, to, dist, energy): number

Parameters

Name Type
from LocationId
to undefined | LocationId
dist undefined | number
energy number

Returns

number


getEnergyCurveAtPercent

getEnergyCurveAtPercent(planet, percent): number

Parameters

Name Type
planet Planet
percent number

Returns

number


getEnergyOfPlayer

getEnergyOfPlayer(player): number

Parameters

Name Type
player EthAddress

Returns

number


getEthConnection

getEthConnection(): EthConnection

Returns

EthConnection


getExploredChunks

getExploredChunks(): Iterable<Chunk>

Returns

Iterable<Chunk>


getForcesSending

getForcesSending(planetId?): number

Percent from 0 to 100.

Parameters

Name Type
planetId? LocationId

Returns

number


getGameManager

getGameManager(): default

Returns

default


getGameObjects

getGameObjects(): GameObjects

Gets a reference to the game's internal representation of the world state. Beware! Use this for reading only, otherwise you might mess up the state of the game. You can try modifying the game state in some way

Returns

GameObjects


getGlManager

getGlManager(): null | GameGLManager

Returns

null | GameGLManager

  • A wrapper class for the WebGL2RenderingContext.

getHashConfig

getHashConfig(): HashConfig

Returns

HashConfig


getHashesPerSec

getHashesPerSec(): number

Returns

number


getHomeCoords

getHomeCoords(): WorldCoords

Returns

WorldCoords


getHomeHash

getHomeHash(): undefined | LocationId

Returns

undefined | LocationId


getHomePlanet

getHomePlanet(): undefined | Planet

Returns

undefined | Planet


getHoveringOverCoords

getHoveringOverCoords(): undefined | WorldCoords

Returns

undefined | WorldCoords


getHoveringOverPlanet

getHoveringOverPlanet(): undefined | Planet

Returns

undefined | Planet


getIsChoosingTargetPlanet

getIsChoosingTargetPlanet(): boolean

Returns

boolean


getIsHighPerfMode

getIsHighPerfMode(): boolean

Returns

boolean


getLocationOfPlanet

getLocationOfPlanet(planetId): undefined | WorldLocation

Parameters

Name Type
planetId LocationId

Returns

undefined | WorldLocation


getLocationsAndChunks

getLocationsAndChunks(): Object

Returns

Object

Name Type
cachedPlanets Map<LocationId, PlanetRenderInfo>
chunks Set<Chunk>

getMinerLocation

getMinerLocation(): undefined | WorldCoords

Returns

undefined | WorldCoords


getMiningPattern

getMiningPattern(): undefined | MiningPattern

Returns

undefined | MiningPattern


getModalManager

getModalManager(): default

Returns

default


getMouseDownCoords

getMouseDownCoords(): undefined | WorldCoords

Returns

undefined | WorldCoords


getMouseDownPlanet

getMouseDownPlanet(): undefined | LocatablePlanet

Returns

undefined | LocatablePlanet


getMyArtifactMap

getMyArtifactMap(): Map<ArtifactId, Artifact>

Returns

Map<ArtifactId, Artifact>


getMyArtifacts

getMyArtifacts(): Artifact[]

Returns

Artifact[]


getMyArtifactsNotOnPlanet

getMyArtifactsNotOnPlanet(): Artifact[]

Returns

Artifact[]


getMyBalance

getMyBalance(): number

Returns

number


getMyBalance$

getMyBalance$(): Monomitter<BigNumber>

Returns

Monomitter<BigNumber>


getMyBalanceBn

getMyBalanceBn(): BigNumber

Returns

BigNumber


getMyPlanetMap

getMyPlanetMap(): Map<LocationId, Planet>

Returns

Map<LocationId, Planet>


getMyScore

getMyScore(): undefined | number

Returns

undefined | number


getNextBroadcastAvailableTimestamp

getNextBroadcastAvailableTimestamp(): number

Returns

number


getOverlayContainer

getOverlayContainer(): undefined | HTMLDivElement

Gets the overlay container. See {@link GameUIManger.overlayContainer} for more information about what the overlay container is.

Returns

undefined | HTMLDivElement


getPaused

getPaused(): boolean

Returns

boolean


getPaused$

getPaused$(): Monomitter<boolean>

Returns

Monomitter<boolean>


getPerlinConfig

getPerlinConfig(isBiome?): PerlinConfig

Parameters

Name Type Default value
isBiome boolean false

Returns

PerlinConfig


getPerlinThresholds

getPerlinThresholds(): [number, number, number]

Returns

[number, number, number]


getPlanetHoveringInRenderer

getPlanetHoveringInRenderer(): boolean

If there is a planet being hovered over, returns whether or not it's being hovered over in the renderer.

Returns

boolean


getPlanetLevel

getPlanetLevel(planetId): undefined | PlanetLevel

Parameters

Name Type
planetId LocationId

Returns

undefined | PlanetLevel


getPlanetMap

getPlanetMap(): Map<LocationId, Planet>

Returns

Map<LocationId, Planet>


getPlanetWithCoords

getPlanetWithCoords(coords): undefined | Planet

Parameters

Name Type
coords undefined | WorldCoords

Returns

undefined | Planet


getPlanetWithId

getPlanetWithId(planetId): undefined | Planet

Parameters

Name Type
planetId undefined | LocationId

Returns

undefined | Planet


getPlanetsInViewport

getPlanetsInViewport(): Planet[]

Returns

Planet[]


getPlayer

getPlayer(address?): undefined | Player

Parameters

Name Type
address? EthAddress

Returns

undefined | Player


getPlayerScore

getPlayerScore(player): undefined | number

Parameters

Name Type
player EthAddress

Returns

undefined | number


getPluginManager

getPluginManager(): PluginManager

Returns

PluginManager


getPreviousSelectedPlanet

getPreviousSelectedPlanet(): undefined | Planet

Returns

undefined | Planet


getPrivateKey

getPrivateKey(): undefined | string

Returns

undefined | string


getRadiusOfPlanetLevel

getRadiusOfPlanetLevel(planetRarity): number

Parameters

Name Type
planetRarity PlanetLevel

Returns

number


getRangeBuff

getRangeBuff(): number

Returns

number


getRenderer

getRenderer(): null | Renderer

Returns

null | Renderer


getSelectedCoords

getSelectedCoords(): undefined | WorldCoords

Returns

undefined | WorldCoords


getSelectedPlanet

getSelectedPlanet(): undefined | LocatablePlanet

Returns

undefined | LocatablePlanet


getSilverCurveAtPercent

getSilverCurveAtPercent(planet, percent): undefined | number

Parameters

Name Type
planet Planet
percent number

Returns

undefined | number


getSilverOfPlayer

getSilverOfPlayer(player): number

Parameters

Name Type
player EthAddress

Returns

number


getSilverScoreValue

getSilverScoreValue(): number

Returns

number


getSilverSending

getSilverSending(planetId?): number

Percent from 0 to 100.

Parameters

Name Type
planetId? LocationId

Returns

number


getSpaceJunkEnabled

getSpaceJunkEnabled(): boolean

Returns

boolean


getSpaceTypePerlin

getSpaceTypePerlin(coords, floor): number

Parameters

Name Type
coords WorldCoords
floor boolean

Returns

number


getSpeedBuff

getSpeedBuff(): number

Returns

number


getStringSetting

getStringSetting(setting): undefined | string

Parameters

Name Type
setting Setting

Returns

undefined | string


getTerminal

getTerminal(): undefined | TerminalHandle

Returns

undefined | TerminalHandle


getTwitter

getTwitter(address): undefined | string

Parameters

Name Type
address undefined | EthAddress

Returns

undefined | string


getUIEmitter

getUIEmitter(): default

Returns

default


getUnconfirmedMoves

getUnconfirmedMoves(): Transaction<UnconfirmedMove>[]

todo delete this. now that GameObjects is publically accessible, we shouldn't need to drill fields like this anymore.

tutorial Plugin developers, please access fields like this with something like {@code df.getGameObjects().}

deprecated

Returns

Transaction<UnconfirmedMove>[]


getUnconfirmedUpgrades

getUnconfirmedUpgrades(): Transaction<UnconfirmedUpgrade>[]

Returns

Transaction<UnconfirmedUpgrade>[]


getUnconfirmedWormholeActivations

getUnconfirmedWormholeActivations(): Transaction<UnconfirmedActivateArtifact>[]

Returns

Transaction<UnconfirmedActivateArtifact>[]


getUniverseTotalEnergy

getUniverseTotalEnergy(): number

Returns

number


getUpgrade

getUpgrade(branch, level): Upgrade

Parameters

Name Type
branch UpgradeBranchName
level number

Returns

Upgrade


getViewport

getViewport(): default

Returns

default


getWorldRadius

getWorldRadius(): number

Returns

number


getWorldSilver

getWorldSilver(): number

Returns

number


getWormholes

getWormholes(): Iterable<Wormhole>

Returns

Iterable<Wormhole>


hasMinedChunk

hasMinedChunk(chunkLocation): boolean

Parameters

Name Type
chunkLocation Rectangle

Returns

boolean


isAbandoning

isAbandoning(): boolean

Returns

boolean


isAdmin

isAdmin(): boolean

Returns

boolean


isCurrentlyRevealing

isCurrentlyRevealing(): boolean

Returns

boolean


isMining

isMining(): boolean

Returns

boolean


isOverOwnPlanet

isOverOwnPlanet(coords): undefined | Planet

Parameters

Name Type
coords WorldCoords

Returns

undefined | Planet


isOwnedByMe

isOwnedByMe(planet): boolean

Parameters

Name Type
planet Planet

Returns

boolean


isRoundOver

isRoundOver(): boolean

Returns

boolean


isSendingForces

isSendingForces(): boolean

Returns

boolean


isSendingShip

isSendingShip(planetId?): boolean

Parameters

Name Type
planetId? LocationId

Returns

boolean


joinGame

joinGame(beforeRetry): Promise<void>

Parameters

Name Type
beforeRetry (e: Error) => Promise<boolean>

Returns

Promise<void>


onDiscoveredChunk

onDiscoveredChunk(chunk): void

Parameters

Name Type
chunk Chunk

Returns

void


onEmitInitializedPlayer

Private onEmitInitializedPlayer(): void

Returns

void


onEmitInitializedPlayerError

Private onEmitInitializedPlayerError(err): void

Parameters

Name Type
err ReactNode

Returns

void


onMouseClick

onMouseClick(_coords): void

Parameters

Name Type
_coords WorldCoords

Returns

void


onMouseDown

onMouseDown(coords): void

Parameters

Name Type
coords WorldCoords

Returns

void


onMouseMove

onMouseMove(coords): void

Parameters

Name Type
coords WorldCoords

Returns

void


onMouseOut

onMouseOut(): void

Returns

void


onMouseUp

onMouseUp(coords): void

Parameters

Name Type
coords WorldCoords

Returns

void


onSendCancel

onSendCancel(): void

Returns

void


onSendComplete

onSendComplete(locationId): void

Parameters

Name Type
locationId LocationId

Returns

void


onSendInit

onSendInit(planet): void

Parameters

Name Type
planet undefined | LocatablePlanet

Returns

void


potentialCaptureScore

potentialCaptureScore(planetLevel): number

Parameters

Name Type
planetLevel number

Returns

number


prospectPlanet

prospectPlanet(planetId): void

Parameters

Name Type
planetId LocationId

Returns

void


removeExtraMinerLocation

removeExtraMinerLocation(idx): void

Parameters

Name Type
idx number

Returns

void


revealLocation

revealLocation(locationId): void

Parameters

Name Type
locationId LocationId

Returns

void


setAbandoning

setAbandoning(abandoning): void

Parameters

Name Type
abandoning boolean

Returns

void


setArtifactSending

setArtifactSending(planetId, artifact?): void

Parameters

Name Type
planetId LocationId
artifact? Artifact

Returns

void


setCustomRenderer

setCustomRenderer(customRenderer): void

Replaces the current renderer with the passed in custom renderer and adds the renderer to the rendering stack. The function will automatically determine which renderer it is by the rendererType and the methods in the renderer.

Parameters

Name Type Description
customRenderer BaseRenderer a Renderer that follows one of the 23 renderer tempaltes

Returns

void


setExtraMinerLocation

setExtraMinerLocation(idx, coords): void

Parameters

Name Type
idx number
coords WorldCoords

Returns

void


setForcesSending

setForcesSending(planetId, percentage): void

Parameters

Name Type
planetId LocationId
percentage number

Returns

void


setHoveringOverArtifact

setHoveringOverArtifact(artifactId?): void

Parameters

Name Type
artifactId? ArtifactId

Returns

void


setHoveringOverPlanet

setHoveringOverPlanet(planet, inRenderer): void

Parameters

Name Type
planet undefined | LocatablePlanet
inRenderer boolean

Returns

void


setMiningPattern

setMiningPattern(pattern): void

Parameters

Name Type
pattern MiningPattern

Returns

void


setModalManager

Private setModalManager(modalManager): void

Parameters

Name Type
modalManager default

Returns

void


setOverlayContainer

setOverlayContainer(randomContainer?): void

Sets the overlay container. See {@link GameUIManger.overlayContainer} for more information about what the overlay container is.

Parameters

Name Type
randomContainer? HTMLDivElement

Returns

void


setSelectedId

setSelectedId(id): void

Parameters

Name Type
id LocationId

Returns

void


setSelectedPlanet

setSelectedPlanet(planet): void

Parameters

Name Type
planet undefined | LocatablePlanet

Returns

void


setSending

setSending(sending): void

Parameters

Name Type
sending boolean

Returns

void


setSilverSending

setSilverSending(planetId, percentage): void

Parameters

Name Type
planetId LocationId
percentage number

Returns

void


spaceTypeFromPerlin

spaceTypeFromPerlin(perlin): SpaceType

Parameters

Name Type
perlin number

Returns

SpaceType


startExplore

startExplore(): void

Returns

void


startWormholeFrom

startWormholeFrom(planet): Promise<undefined | LocatablePlanet>

Parameters

Name Type
planet LocatablePlanet

Returns

Promise<undefined | LocatablePlanet>


stopExplore

stopExplore(): void

Returns

void


timeUntilNextBroadcastAvailable

timeUntilNextBroadcastAvailable(): number

Returns

number


toggleExplore

toggleExplore(): void

Returns

void


toggleTargettingExplorer

toggleTargettingExplorer(): void

Returns

void


updateDiagnostics

updateDiagnostics(updateFn): void

Parameters

Name Type
updateFn (d: Diagnostics) => void

Returns

void


updateMouseHoveringOverCoords

Private updateMouseHoveringOverCoords(coords): WorldCoords

Parameters

Name Type
coords WorldCoords

Returns

WorldCoords


updatePlanets

Private updatePlanets(): void

Returns

void


upgrade

upgrade(planet, branch): void

Parameters

Name Type
planet Planet
branch number

Returns

void


verifyTwitter

verifyTwitter(twitter): Promise<boolean>

Parameters

Name Type
twitter string

Returns

Promise<boolean>


withdrawArtifact

withdrawArtifact(locationId, artifactId): void

Parameters

Name Type
locationId LocationId
artifactId ArtifactId

Returns

void


withdrawSilver

withdrawSilver(locationId, amount): void

Parameters

Name Type
locationId LocationId
amount number

Returns

void


create

Static create(gameManager, terminalHandle): Promise<default>

Parameters

Name Type
gameManager default
terminalHandle MutableRefObject<undefined | TerminalHandle>

Returns

Promise<default>