C#

Download the ProudChat C# SDK from the link below.

Project settings

Add the DotNetProudChat project file from the SDK folder you downloaded via git to your solution.

In the root project, reference DotNetProudChat by adding a project reference.

ChatClient object

- Creating

Proud.ChatClient chatClient = new Proud.ChatClient();

- ChatClient.Init

This is the part that initializes the ChatClient. The user must call the Init function to connect to the server before using it.

Function NameParametersDescription

Init

The user's UUID provided in the Proud Console, the UUID of a project created by the user, and the user's own UniqueID, Events to be called when Server Connection succeeds, events to be called when Server Login fails

You write this part of the function to connect the ChatClient with the server. As parameters, it takes a string to initialize the project (authUUID, projectUUID, uniqueID) and two events to check if the login succeeded or failed.

- Function

Function NameParametersDescription

Add_Channel

Unique key for the channel you want to access

Use when you want to access a specific channel.

Leave_Channel

Unique key for the channel you want to leave

Use this when you want to leave the channel you're in.

Send_Msg

A unique identification value for a specific recipient, a message to send to the specific party

Use to send a message to a specific recipient.

Send_ChannelMsg

A unique identification value in null, a message to send to a specific channel

Use to send a message to a specific channel.

- Event variable

Event function nameDescription

chatClientJoinCompleteDelegate

Event fired when ChatClient completes Init Users can register and use Events.

chatClientJoinFailedDelegate

Events fired when ChatClient Init Failed Users can register and use Event. Returns the error message received as a parameter.

channelMsg_ResponseDelegate

Event that occurs when a Channel Message arrives Users can register and use the Event. As parameters, it receives the Unique ID of the channel from which the message came, the Unique ID of the target that generated the message, and the message sent by the other party.

sendMsg_ResponseDelegate

Event when the send message arrives. Users can register and use the Event. As parameters, the Unique ID of the target that generated the message and the Unique ID of the other party are received.

notice_ResponseDelegate

Event processing is performed when the notice arrives. Users can register and use the Event. Returns the content of the notice received as a parameter.

- Event Function

Function NameDescription

ChannelMsg_Stub

It handles events that occur when a ChannelMsg arrives. It receives the Unique ID of the channel from which the message came, the Unique ID that generated the message, and the message sent by the other party as parameters.

SendMsg_Stub

Handles events that occur when a Send_Msg arrives between users. It receives the Unique ID that generated the message and the message sent by the other party as parameters.

Event_Notice

Handle the event when the notice arrives. Functions delegated when sending an announcement in Proud Console

Last updated