-
Notifications
You must be signed in to change notification settings - Fork 1
Core
YYBartT edited this page Jul 15, 2024
·
9 revisions
This function initialises the Discord extension and returns whether this was successful.
The creationFlag
parameter determines if the Discord extension requires or doesn't require Discord to be running. If creationFlag
is set to Discord_CreateFlags_Default
and Discord is not running, it will:
- Close your game
- Open Discord
- Attempt to re-open your game
Discord_Core_Create(appId, creationFlag)
Argument | Type | Description |
---|---|---|
appId | int64 | Application identifier |
creationFlag | Discord_CreateFlags |
Discord_CreateFlags_Default or Discord_CreateFlags_NoRequireDiscord
|
if(!Discord_Core_Create(_applicationId, Discord_CreateFlags_Default))
{
show_message_async("Discord Initialization Error");
exit;
}
Requests the extension instances to do work.
⚠️ IMPORTANT It is imperative that this function is called at regular intervals to ensure that all the services offered by the SDK function optimally.
Discord_Core_RunCallbacks()
N/A
/// Step Event
Discord_Core_RunCallbacks();
Constant | Value | Description |
---|---|---|
Discord_OK | 0 | A constant that indicates that the result is OK. |
Discord Enum: CreateFlags Enum
Constant | Value | Description |
---|---|---|
Discord_CreateFlags_Default | 0 | Requires Discord to be running to play the game |
Discord_CreateFlags_NoRequireDiscord | 1 | Does not require Discord to be running, use this on other platforms |
YoYoGames 2024