more towards building
This commit is contained in:
3
.gitignore
vendored
3
.gitignore
vendored
@@ -25,6 +25,9 @@ build/
|
|||||||
src/lib/discord_social_sdk/*
|
src/lib/discord_social_sdk/*
|
||||||
src/lib/godot-cpp/*
|
src/lib/godot-cpp/*
|
||||||
*.zip
|
*.zip
|
||||||
|
*.so
|
||||||
|
*.dll
|
||||||
|
*.dylib
|
||||||
|
|
||||||
# release
|
# release
|
||||||
release/
|
release/
|
||||||
|
@@ -21,10 +21,11 @@ elif env["platform"] == "windows":
|
|||||||
if env["target"] == "template_debug":
|
if env["target"] == "template_debug":
|
||||||
debugsuffix = "_debug"
|
debugsuffix = "_debug"
|
||||||
folder = "debug/"
|
folder = "debug/"
|
||||||
|
discord_library_target = discord_library.replace(".", f"{debugsuffix}.")
|
||||||
else:
|
else:
|
||||||
debugsuffix = ""
|
debugsuffix = ""
|
||||||
folder = "release/" #
|
folder = "release/"
|
||||||
|
discord_library_target = discord_library
|
||||||
|
|
||||||
env.Append(LIBPATH=["src/lib/discord_social_sdk/lib/" + folder])
|
env.Append(LIBPATH=["src/lib/discord_social_sdk/lib/" + folder])
|
||||||
env.Append(LIBS=["discord_partner_sdk"])
|
env.Append(LIBS=["discord_partner_sdk"])
|
||||||
@@ -41,8 +42,8 @@ library = env.SharedLibrary(
|
|||||||
env.Depends(
|
env.Depends(
|
||||||
library,
|
library,
|
||||||
Command(
|
Command(
|
||||||
"project/addons/discord-rpc-gd/bin/" + libexportfolder + discord_library,
|
"project/addons/discord-rpc-gd/bin/" + libexportfolder + discord_library_target,
|
||||||
"src/lib/discord_partner_sdk/bin/" + folder + discord_library,
|
"src/lib/discord_social_sdk/lib/" + folder + discord_library,
|
||||||
Copy("$TARGET", "$SOURCE"),
|
Copy("$TARGET", "$SOURCE"),
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
@@ -19,11 +19,11 @@ linux.release.rv64 = "linux/libdiscord_partner_sdk_binding.so"
|
|||||||
[dependencies]
|
[dependencies]
|
||||||
|
|
||||||
macos = { "macos/libdiscord_partner_sdk.dylib": "" }
|
macos = { "macos/libdiscord_partner_sdk.dylib": "" }
|
||||||
windows.debug.x86_64 = { "windows/discord_partner_sdk.dll": "" }
|
windows.debug.x86_64 = { "windows/discord_partner_sdk_debug.dll": "" }
|
||||||
windows.release.x86_64 = { "windows/discord_partner_sdk.dll": "" }
|
windows.release.x86_64 = { "windows/discord_partner_sdk.dll": "" }
|
||||||
linux.debug.x86_64 = { "linux/libdiscord_partner_sdk.so": "" }
|
linux.debug.x86_64 = { "linux/libdiscord_partner_sdk_debug.so": "" }
|
||||||
linux.release.x86_64 = { "linux/libdiscord_partner_sdk.so": "" }
|
linux.release.x86_64 = { "linux/libdiscord_partner_sdk.so": "" }
|
||||||
linux.debug.arm64 = { "linux/libdiscord_partner_sdk.so": "" }
|
linux.debug.arm64 = { "linux/libdiscord_partner_sdk_debug.so": "" }
|
||||||
linux.release.arm64 = { "linux/libdiscord_partner_sdk.so": "" }
|
linux.release.arm64 = { "linux/libdiscord_partner_sdk.so": "" }
|
||||||
linux.debug.rv64 = { "linux/libdiscord_partner_sdk.so": "" }
|
linux.debug.rv64 = { "linux/libdiscord_partner_sdk_debug.so": "" }
|
||||||
linux.release.rv64 = { "linux/libdiscord_partner_sdk.so": "" }
|
linux.release.rv64 = { "linux/libdiscord_partner_sdk.so": "" }
|
||||||
|
@@ -0,0 +1 @@
|
|||||||
|
uid://jcdwy5o1utpj
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
1
project/addons/discord-rpc-gd/example.gd.uid
Normal file
1
project/addons/discord-rpc-gd/example.gd.uid
Normal file
@@ -0,0 +1 @@
|
|||||||
|
uid://dkv4pruvla8bn
|
@@ -115,8 +115,8 @@ tracks/0/keys = {
|
|||||||
|
|
||||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_a7ofc"]
|
[sub_resource type="AnimationLibrary" id="AnimationLibrary_a7ofc"]
|
||||||
_data = {
|
_data = {
|
||||||
"RESET": SubResource("Animation_mmtmn"),
|
&"RESET": SubResource("Animation_mmtmn"),
|
||||||
"pulsate": SubResource("Animation_5u02v")
|
&"pulsate": SubResource("Animation_5u02v")
|
||||||
}
|
}
|
||||||
|
|
||||||
[node name="DebugNodeGroup" type="Node"]
|
[node name="DebugNodeGroup" type="Node"]
|
||||||
|
1
project/addons/discord-rpc-gd/nodes/debug.gd.uid
Normal file
1
project/addons/discord-rpc-gd/nodes/debug.gd.uid
Normal file
@@ -0,0 +1 @@
|
|||||||
|
uid://46tue7u6crd6
|
@@ -0,0 +1 @@
|
|||||||
|
uid://d1ohgxo4k3cdf
|
1
project/addons/discord-rpc-gd/plugin.gd.uid
Normal file
1
project/addons/discord-rpc-gd/plugin.gd.uid
Normal file
@@ -0,0 +1 @@
|
|||||||
|
uid://citpv7uf0k1ku
|
@@ -9,7 +9,7 @@ Button/styles/focus = SubResource("StyleBoxEmpty_1t7mm")
|
|||||||
|
|
||||||
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_5vqdt"]
|
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_5vqdt"]
|
||||||
|
|
||||||
[sub_resource type="Image" id="Image_f4u3i"]
|
[sub_resource type="Image" id="Image_4rf8i"]
|
||||||
data = {
|
data = {
|
||||||
"data": PackedByteArray(255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 168, 224, 224, 224, 233, 224, 224, 224, 236, 224, 224, 224, 170, 231, 231, 231, 31, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 234, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 239, 230, 230, 230, 30, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 168, 224, 224, 224, 255, 224, 224, 224, 186, 224, 224, 224, 32, 224, 224, 224, 33, 224, 224, 224, 187, 224, 224, 224, 255, 225, 225, 225, 167, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 237, 224, 224, 224, 255, 224, 224, 224, 33, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 255, 224, 224, 224, 234, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 237, 224, 224, 224, 255, 224, 224, 224, 33, 255, 255, 255, 0, 255, 255, 255, 0, 229, 229, 229, 38, 224, 224, 224, 255, 224, 224, 224, 229, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 164, 224, 224, 224, 255, 224, 224, 224, 187, 225, 225, 225, 34, 227, 227, 227, 36, 224, 224, 224, 192, 224, 224, 224, 255, 224, 224, 224, 162, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 24, 225, 225, 225, 215, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 229, 224, 224, 224, 32, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 24, 224, 224, 224, 216, 224, 224, 224, 255, 224, 224, 224, 210, 224, 224, 224, 161, 224, 224, 224, 232, 224, 224, 224, 231, 225, 225, 225, 159, 230, 230, 230, 30, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 107, 224, 224, 224, 255, 224, 224, 224, 210, 230, 230, 230, 20, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 105, 230, 230, 230, 20, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 221, 224, 224, 224, 130, 255, 255, 255, 1, 255, 255, 255, 1, 225, 225, 225, 134, 224, 224, 224, 224, 225, 225, 225, 223, 224, 224, 224, 132, 255, 255, 255, 1, 255, 255, 255, 6, 224, 224, 224, 137, 224, 224, 224, 231, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 130, 225, 225, 225, 133, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 129, 224, 224, 224, 137, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 65, 224, 224, 224, 255, 224, 224, 224, 220, 225, 225, 225, 223, 224, 224, 224, 255, 226, 226, 226, 61, 224, 224, 224, 65, 224, 224, 224, 255, 224, 224, 224, 222, 224, 224, 224, 231, 224, 224, 224, 255, 227, 227, 227, 62, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 67, 224, 224, 224, 255, 224, 224, 224, 219, 224, 224, 224, 222, 224, 224, 224, 255, 227, 227, 227, 63, 225, 225, 225, 67, 224, 224, 224, 255, 224, 224, 224, 219, 224, 224, 224, 230, 224, 224, 224, 255, 227, 227, 227, 63, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 127, 224, 224, 224, 129, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 126, 225, 225, 225, 135, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 221, 225, 225, 225, 127, 255, 255, 255, 0, 255, 255, 255, 1, 224, 224, 224, 128, 224, 224, 224, 220, 224, 224, 224, 219, 225, 225, 225, 127, 255, 255, 255, 0, 255, 255, 255, 5, 225, 225, 225, 134, 224, 224, 224, 229, 224, 224, 224, 255, 255, 255, 255, 0),
|
"data": PackedByteArray(255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 168, 224, 224, 224, 233, 224, 224, 224, 236, 224, 224, 224, 170, 231, 231, 231, 31, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 234, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 239, 230, 230, 230, 30, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 168, 224, 224, 224, 255, 224, 224, 224, 186, 224, 224, 224, 32, 224, 224, 224, 33, 224, 224, 224, 187, 224, 224, 224, 255, 225, 225, 225, 167, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 237, 224, 224, 224, 255, 224, 224, 224, 33, 255, 255, 255, 0, 255, 255, 255, 0, 227, 227, 227, 36, 224, 224, 224, 255, 224, 224, 224, 234, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 237, 224, 224, 224, 255, 224, 224, 224, 33, 255, 255, 255, 0, 255, 255, 255, 0, 229, 229, 229, 38, 224, 224, 224, 255, 224, 224, 224, 229, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 164, 224, 224, 224, 255, 224, 224, 224, 187, 225, 225, 225, 34, 227, 227, 227, 36, 224, 224, 224, 192, 224, 224, 224, 255, 224, 224, 224, 162, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 24, 225, 225, 225, 215, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 229, 224, 224, 224, 32, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 24, 224, 224, 224, 216, 224, 224, 224, 255, 224, 224, 224, 210, 224, 224, 224, 161, 224, 224, 224, 232, 224, 224, 224, 231, 225, 225, 225, 159, 230, 230, 230, 30, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 107, 224, 224, 224, 255, 224, 224, 224, 210, 230, 230, 230, 20, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 105, 230, 230, 230, 20, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 221, 224, 224, 224, 130, 255, 255, 255, 1, 255, 255, 255, 1, 225, 225, 225, 134, 224, 224, 224, 224, 225, 225, 225, 223, 224, 224, 224, 132, 255, 255, 255, 1, 255, 255, 255, 6, 224, 224, 224, 137, 224, 224, 224, 231, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 130, 225, 225, 225, 133, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 129, 224, 224, 224, 137, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 65, 224, 224, 224, 255, 224, 224, 224, 220, 225, 225, 225, 223, 224, 224, 224, 255, 226, 226, 226, 61, 224, 224, 224, 65, 224, 224, 224, 255, 224, 224, 224, 222, 224, 224, 224, 231, 224, 224, 224, 255, 227, 227, 227, 62, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 67, 224, 224, 224, 255, 224, 224, 224, 219, 224, 224, 224, 222, 224, 224, 224, 255, 227, 227, 227, 63, 225, 225, 225, 67, 224, 224, 224, 255, 224, 224, 224, 219, 224, 224, 224, 230, 224, 224, 224, 255, 227, 227, 227, 63, 255, 255, 255, 0, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 127, 224, 224, 224, 129, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 225, 225, 225, 126, 225, 225, 225, 135, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 255, 255, 255, 255, 0, 224, 224, 224, 255, 224, 224, 224, 255, 224, 224, 224, 221, 225, 225, 225, 127, 255, 255, 255, 0, 255, 255, 255, 1, 224, 224, 224, 128, 224, 224, 224, 220, 224, 224, 224, 219, 225, 225, 225, 127, 255, 255, 255, 0, 255, 255, 255, 5, 225, 225, 225, 134, 224, 224, 224, 229, 224, 224, 224, 255, 255, 255, 255, 0),
|
||||||
"format": "RGBA8",
|
"format": "RGBA8",
|
||||||
@@ -19,7 +19,7 @@ data = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
[sub_resource type="ImageTexture" id="ImageTexture_gdtpn"]
|
[sub_resource type="ImageTexture" id="ImageTexture_gdtpn"]
|
||||||
image = SubResource("Image_f4u3i")
|
image = SubResource("Image_4rf8i")
|
||||||
|
|
||||||
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_7v0rg"]
|
[sub_resource type="StyleBoxEmpty" id="StyleBoxEmpty_7v0rg"]
|
||||||
|
|
||||||
|
1
project/main.gd.uid
Normal file
1
project/main.gd.uid
Normal file
@@ -0,0 +1 @@
|
|||||||
|
uid://e0nds76y78bx
|
@@ -1,8 +1,8 @@
|
|||||||
[gd_scene load_steps=4 format=3 uid="uid://dyc3kseph4el7"]
|
[gd_scene load_steps=4 format=3 uid="uid://dyc3kseph4el7"]
|
||||||
|
|
||||||
[ext_resource type="Script" path="res://main.gd" id="1_kl8ri"]
|
[ext_resource type="Script" uid="uid://e0nds76y78bx" path="res://main.gd" id="1_kl8ri"]
|
||||||
[ext_resource type="Texture2D" uid="uid://b3qm246m7pnsx" path="res://assets/Logo_V2.png" id="2_gd222"]
|
[ext_resource type="Texture2D" uid="uid://b3qm246m7pnsx" path="res://assets/Logo_V2.png" id="2_gd222"]
|
||||||
[ext_resource type="Script" path="res://addons/discord-rpc-gd/nodes/debug.gd" id="6_ujijw"]
|
[ext_resource type="Script" uid="uid://46tue7u6crd6" path="res://addons/discord-rpc-gd/nodes/debug.gd" id="6_ujijw"]
|
||||||
|
|
||||||
[node name="Node" type="Node"]
|
[node name="Node" type="Node"]
|
||||||
script = ExtResource("1_kl8ri")
|
script = ExtResource("1_kl8ri")
|
||||||
|
1
project/plugin_manager.gd.uid
Normal file
1
project/plugin_manager.gd.uid
Normal file
@@ -0,0 +1 @@
|
|||||||
|
uid://pi17u5foe8ti
|
@@ -13,15 +13,16 @@ config_version=5
|
|||||||
config/name="GDExtension DiscordRPC Test Project"
|
config/name="GDExtension DiscordRPC Test Project"
|
||||||
config/tags=PackedStringArray("vaporvee")
|
config/tags=PackedStringArray("vaporvee")
|
||||||
run/main_scene="res://main.tscn"
|
run/main_scene="res://main.tscn"
|
||||||
config/features=PackedStringArray("4.3")
|
config/features=PackedStringArray("4.4")
|
||||||
boot_splash/bg_color=Color(0.25098, 0.305882, 0.929412, 1)
|
boot_splash/bg_color=Color(0.25098, 0.305882, 0.929412, 1)
|
||||||
boot_splash/image="res://assets/discordgodot_cover.png"
|
|
||||||
boot_splash/fullsize=false
|
boot_splash/fullsize=false
|
||||||
|
boot_splash/image="res://assets/discordgodot_cover.png"
|
||||||
config/icon="res://assets/Logo_V2.png"
|
config/icon="res://assets/Logo_V2.png"
|
||||||
|
|
||||||
[autoload]
|
[autoload]
|
||||||
|
|
||||||
PluginManager="*res://plugin_manager.gd"
|
PluginManager="*res://plugin_manager.gd"
|
||||||
|
DiscordRPCLoader="*res://addons/discord-rpc-gd/nodes/discord_autoload.gd"
|
||||||
|
|
||||||
[debug]
|
[debug]
|
||||||
|
|
||||||
@@ -40,6 +41,10 @@ window/size/resizable=false
|
|||||||
|
|
||||||
project/assembly_name="GDExtension Test Project"
|
project/assembly_name="GDExtension Test Project"
|
||||||
|
|
||||||
|
[editor_plugins]
|
||||||
|
|
||||||
|
enabled=PackedStringArray("res://addons/discord-rpc-gd/plugin.cfg")
|
||||||
|
|
||||||
[filesystem]
|
[filesystem]
|
||||||
|
|
||||||
import/blender/enabled=false
|
import/blender/enabled=false
|
||||||
|
@@ -19,9 +19,7 @@
|
|||||||
|
|
||||||
DiscordRPC *DiscordRPC::singleton = nullptr;
|
DiscordRPC *DiscordRPC::singleton = nullptr;
|
||||||
std::shared_ptr<discordpp::Client> client;
|
std::shared_ptr<discordpp::Client> client;
|
||||||
discordpp::ClientResult result;
|
|
||||||
discordpp::Activity activity;
|
discordpp::Activity activity;
|
||||||
discordpp::UserHandle user;
|
|
||||||
|
|
||||||
void DiscordRPC::_bind_methods()
|
void DiscordRPC::_bind_methods()
|
||||||
{
|
{
|
||||||
@@ -52,7 +50,6 @@ void DiscordRPC::_bind_methods()
|
|||||||
BIND_METHOD(open_server_invite_overlay, "invite_code");
|
BIND_METHOD(open_server_invite_overlay, "invite_code");
|
||||||
BIND_METHOD(open_voice_settings);
|
BIND_METHOD(open_voice_settings);
|
||||||
BIND_METHOD(get_is_discord_working);
|
BIND_METHOD(get_is_discord_working);
|
||||||
BIND_METHOD(get_result_int);
|
|
||||||
}
|
}
|
||||||
SET_GET(state, activity.SetState(value.utf8().get_data()))
|
SET_GET(state, activity.SetState(value.utf8().get_data()))
|
||||||
SET_GET(details, activity.SetDetails(value.utf8().get_data()))
|
SET_GET(details, activity.SetDetails(value.utf8().get_data()))
|
||||||
@@ -79,7 +76,7 @@ DiscordRPC *DiscordRPC::get_singleton()
|
|||||||
|
|
||||||
void DiscordRPC::run_callbacks()
|
void DiscordRPC::run_callbacks()
|
||||||
{
|
{
|
||||||
if (result.Successful() && app_id > 0)
|
if (app_id > 0) //result.Successful() &&
|
||||||
discordpp::RunCallbacks();
|
discordpp::RunCallbacks();
|
||||||
}
|
}
|
||||||
void DiscordRPC::debug()
|
void DiscordRPC::debug()
|
||||||
@@ -175,16 +172,21 @@ void DiscordRPC::unclear()
|
|||||||
bool DiscordRPC::get_is_overlay_enabled()
|
bool DiscordRPC::get_is_overlay_enabled()
|
||||||
{
|
{
|
||||||
bool ie;
|
bool ie;
|
||||||
if (get_is_discord_working())
|
if (get_is_discord_working()){
|
||||||
// core->OverlayManager().IsEnabled(&ie);
|
// core->OverlayManager().IsEnabled(&ie);
|
||||||
return ie;
|
return ie;
|
||||||
|
}
|
||||||
|
return ie;
|
||||||
}
|
}
|
||||||
bool DiscordRPC::get_is_overlay_locked()
|
bool DiscordRPC::get_is_overlay_locked()
|
||||||
{
|
{
|
||||||
bool il;
|
bool il;
|
||||||
if (get_is_discord_working())
|
if (get_is_discord_working())
|
||||||
|
{
|
||||||
// core->OverlayManager().IsLocked(&il);
|
// core->OverlayManager().IsLocked(&il);
|
||||||
return il;
|
return il;
|
||||||
|
}
|
||||||
|
return il;
|
||||||
}
|
}
|
||||||
void DiscordRPC::set_is_overlay_locked(bool value)
|
void DiscordRPC::set_is_overlay_locked(bool value)
|
||||||
{
|
{
|
||||||
@@ -250,20 +252,20 @@ Dictionary DiscordRPC::get_current_user()
|
|||||||
{
|
{
|
||||||
// discordpp::User user{};
|
// discordpp::User user{};
|
||||||
// core->UserManager().GetCurrentUser(&user);
|
// core->UserManager().GetCurrentUser(&user);
|
||||||
return user2dict(user);
|
return userdict; //user2dict(user)
|
||||||
}
|
}
|
||||||
return userdict;
|
return userdict;
|
||||||
}
|
}
|
||||||
|
|
||||||
Dictionary DiscordRPC::get_relationship(uint64_t user_id)
|
Dictionary DiscordRPC::get_relationship(uint64_t user_id)
|
||||||
{
|
{
|
||||||
|
Dictionary dict;
|
||||||
if (get_is_discord_working())
|
if (get_is_discord_working())
|
||||||
{
|
{
|
||||||
// discordpp::Relationship relationship{};
|
// discordpp::Relationship relationship{};
|
||||||
// core->RelationshipManager().Get(user_id, &relationship);
|
// core->RelationshipManager().Get(user_id, &relationship);
|
||||||
return /*relationship2dict(relationship)*/;
|
return dict /*relationship2dict(relationship)*/;
|
||||||
}
|
}
|
||||||
Dictionary dict;
|
|
||||||
return dict;
|
return dict;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -374,5 +376,5 @@ Dictionary DiscordRPC::relationship2dict(discordpp::RelationshipHandle relations
|
|||||||
|
|
||||||
bool DiscordRPC::get_is_discord_working()
|
bool DiscordRPC::get_is_discord_working()
|
||||||
{
|
{
|
||||||
return result.Successful() && app_id > 0;
|
return app_id > 0; /*result.Successful() &&*/
|
||||||
}
|
}
|
@@ -59,7 +59,6 @@ public:
|
|||||||
Dictionary get_relationship(uint64_t user_id);
|
Dictionary get_relationship(uint64_t user_id);
|
||||||
Array get_all_relationships();
|
Array get_all_relationships();
|
||||||
bool get_is_discord_working();
|
bool get_is_discord_working();
|
||||||
int get_result_int();
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
Reference in New Issue
Block a user