more precise discord errors
This commit is contained in:
@@ -51,7 +51,7 @@ void Discord_SDK::_bind_methods()
|
||||
|
||||
ClassDB::bind_method(D_METHOD("refresh"), &Discord_SDK::refresh);
|
||||
|
||||
ClassDB::bind_method(D_METHOD("get_is_discord_working"), &Discord_SDK::get_is_discord_working);
|
||||
ClassDB::bind_method(D_METHOD("get_result_int"), &Discord_SDK::get_result_int);
|
||||
}
|
||||
|
||||
Discord_SDK *Discord_SDK::get_singleton()
|
||||
@@ -192,7 +192,7 @@ int64_t Discord_SDK::get_end_timestamp() const
|
||||
return activity.GetTimestamps().GetEnd();
|
||||
}
|
||||
|
||||
bool Discord_SDK::get_is_discord_working() const
|
||||
int Discord_SDK::get_result_int() const
|
||||
{
|
||||
return result == discord::Result::Ok;
|
||||
return static_cast<int>(result);
|
||||
}
|
@@ -2,6 +2,7 @@
|
||||
#define DISCORDGODOT_H
|
||||
|
||||
#include <stdio.h>
|
||||
#include "discord-game-sdk-cpp/discord.h"
|
||||
#include <godot_cpp/classes/object.hpp>
|
||||
#include <godot_cpp/core/class_db.hpp>
|
||||
|
||||
@@ -62,7 +63,7 @@ public:
|
||||
int64_t get_end_timestamp() const;
|
||||
void set_end_timestamp(const int64_t &value);
|
||||
|
||||
bool get_is_discord_working() const;
|
||||
int get_result_int() const;
|
||||
};
|
||||
|
||||
#endif
|
Reference in New Issue
Block a user