DiscordPHP-NHA Documentation

ChannelRelay
in package

FinalYes

Two-way bridge between the default agent and one Discord channel:

  • every $pollInterval seconds, observe the agent and forward the world dashboard when there is a NEW world-chat message or a NEW threat (alerts linger for many ticks, so they are de-duplicated by their tick);
  • a plain message typed in that channel is relayed into the world as a say intent.
Tags
since
3.1.27

Table of Contents

Properties

$channelId  : string
$nha  : NHA
$pollInterval  : float
$seenMessageCount  : int
$seenThreatTick  : int
$state  : StateStore

Methods

__construct()  : mixed
start()  : void

Properties

Methods

__construct()

public __construct(NHA $nha, StateStore $state, string $channelId, float $pollInterval) : mixed
Parameters
$nha : NHA
$state : StateStore
$channelId : string
$pollInterval : float
On this page

Search results