abdera7mane / discord-rpc-gdscript Goto Github PK
View Code? Open in Web Editor NEWDiscord RPC implementation in GDScript language
License: MIT License
Discord RPC implementation in GDScript language
License: MIT License
Problem previously raised here: 3ddelano/godot-editor-discord-presence#9
Godot seems to crash after some amount of time, using the godot-editor-discord-presence plugin that uses this project with the following output:
OpenGL ES 3.0 Renderer: Mesa Intel(R) HD Graphics 5500 (BDW GT2)
OpenGL ES Batching: ON
OPTIONS
max_join_item_commands 16
colored_vertex_format_threshold 0.25
batch_buffer_size 16384
light_scissor_area_threshold 1
item_reordering_lookahead 4
light_max_join_items 32
single_rect_fallback False
debug_flash False
diagnose_frame False
PulseAudio: context other
PulseAudio: context other
PulseAudio: context other
PulseAudio: context ready
PulseAudio: Detecting channels for device: alsa_output.pci-0000_00_1b.0.analog-stereo
PulseAudio: detected 2 output channels
PulseAudio: audio buffer frames: 512 calculated output latency: 11ms
JoypadLinux: udev enabled and loaded successfully.
Loading resource: res://locale/en_US.po
Loading resource: res://locale/pt_PT.po
Loading resource: res://locale/de_DE.po
CORE API HASH: 4983981888327659428
EDITOR API HASH: 17985513469441247513
Construct gdnative interface
Destruct gdnative interface
Class 'BulletPhysicsDirectBodyState' is not exposed, skipping.
Class 'BulletPhysicsDirectSpaceState' is not exposed, skipping.
Class 'BulletPhysicsServer' is not exposed, skipping.
Class 'GDScriptNativeClass' is not exposed, skipping.
Class 'IP_Unix' is not exposed, skipping.
Class 'InputDefault' is not exposed, skipping.
Class 'Physics2DDirectBodyStateSW' is not exposed, skipping.
Class 'Physics2DDirectSpaceStateSW' is not exposed, skipping.
Class 'Physics2DServerSW' is not exposed, skipping.
Class 'ResourceImporterMP3' is not exposed, skipping.
Class 'ResourceImporterOGGVorbis' is not exposed, skipping.
Loading resource: /home/monix/.config/godot/editor_settings-3.tres
EditorSettings: Load OK!
Loading resource: res://src/common/Globals.gd
Loading resource: res://src/common/WorldRWS.gd
Loading resource: res://addons/godot-sqlite/bin/gdsqlite.gdns
Loading resource: res://addons/godot-sqlite/bin/gdsqlite.gdnlib
Loading resource: res://src/common/Network.gd
Loading resource: res://src/common/Events.gd
Loading resource: res://src/common/ClientSettings.gd
Loading resource: res://addons/dialogue_manager/dialogue_manager.gd
Loading resource: res://addons/dialogue_manager/dialogue_resource.gd
Loading resource: res://addons/dialogue_manager/dialogue_line.gd
Loading resource: res://addons/dialogue_manager/constants.gd
Loading resource: res://addons/dialogue_manager/dialogue_response.gd
Loading resource: res://addons/dialogue_manager/components/settings.gd
Loading resource: res://addons/dialogue_manager/components/parser.gd
Loading resource: res://addons/dialogue_manager/example_balloon/example_balloon.gd
Loading resource: res://addons/dialogue_manager/example_balloon/menu_item.tscn
Loading resource: res://addons/dialogue_manager/example_balloon/Open_Sans/OpenSans-Regular.ttf
Loading resource: res://addons/dialogue_manager/example_balloon/menu_item.gd
Loading resource: res://addons/dialogue_manager/example_balloon/example_balloon.tscn
Loading resource: res://addons/dialogue_manager/example_balloon/menu.tscn
Loading resource: res://addons/dialogue_manager/example_balloon/menu.gd
Loading resource: res://addons/dialogue_manager/example_balloon/pointer.svg
Loading resource: res://addons/dialogue_manager/example_balloon/Open_Sans/OpenSans-Bold.ttf
Loading resource: res://addons/dialogue_manager/example_balloon/Open_Sans/OpenSans-Italic.ttf
Loading resource: res://addons/dialogue_manager/dialogue_label.tscn
Loading resource: res://addons/dialogue_manager/dialogue_label.gd
Loading resource: res://addons/dialogue_manager/example_balloon/background.svg
Loading resource: res://src/common/Story.gd
Loaded builtin certs
EditorSettings: Save OK!
Loading resource: res://addons/dialogue_manager/plugin.gd
Loading resource: res://addons/dialogue_manager/editor_export_plugin.gd
Loading resource: res://addons/dialogue_manager/views/main_view.tscn
Loading resource: res://addons/dialogue_manager/components/code_editor.tscn
Loading resource: res://addons/dialogue_manager/components/code_editor.gd
Loading resource: res://addons/dialogue_manager/views/choose_title_dialog.gd
Loading resource: res://addons/dialogue_manager/components/title_list.gd
Loading resource: res://addons/dialogue_manager/views/main_view.gd
Loading resource: res://addons/dialogue_manager/components/title_list.tscn
Loading resource: res://addons/dialogue_manager/views/settings_dialog.tscn
Loading resource: res://addons/dialogue_manager/views/settings_dialog.gd
Loading resource: res://addons/dialogue_manager/components/update_checker.tscn
Loading resource: res://addons/dialogue_manager/components/update_checker.gd
Loading resource: res://addons/dialogue_manager/components/search.tscn
Loading resource: res://addons/dialogue_manager/components/search.gd
Loading resource: res://addons/dialogue_manager/views/new_dialogue_dialog.tscn
Loading resource: res://addons/dialogue_manager/views/choose_title_dialog.tscn
Loading resource: res://addons/dialogue_manager/components/error_list.tscn
Loading resource: res://addons/dialogue_manager/components/error_list.gd
Loading resource: res://addons/dialogue_manager/components/error_button.tscn
Loading resource: res://addons/dialogue_manager/components/error_button_style.tres
Loading resource: res://addons/dialogue_manager/views/open_dialogue_dialog.tscn
Loading resource: res://addons/dialogue_manager/views/invalid_dialogue_dialog.tscn
Loading resource: res://addons/dialogue_manager/views/save_translations_dialog.tscn
Loading resource: res://addons/dialogue_manager/assets/icons/icon_dark_1.svg
Loading resource: res://addons/godot_editor_discord_presence/plugin.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/DiscordRPC.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/module/IPCModule.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/IPC.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/pipe/IPCPipe.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/IPCPayload.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/util/UUID.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/DiscordRPCEnum.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/pipe/WindowsPipe.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/pipe/UnixPipe.gd
Loading resource: res://addons/godot_editor_discord_presence/godot-unix-socket/unix-socket.gdns
Loading resource: res://addons/godot_editor_discord_presence/godot-unix-socket/native_script.gd
Loading resource: res://addons/godot_editor_discord_presence/godot-unix-socket/unix-socket.gdnlib
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/module/rich presence/RichPresenceModule.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/module/rich presence/RichPresence.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/module/rich presence/RichPresenceButton.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/ipc/module/rich presence/UpdateRichPresencePayload.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/util/IPCUtil.gd
Loading resource: res://addons/godot_editor_discord_presence/Discord RPC/util/URLUtil.gd
Loading resource: res://src/server/Chat.gd
Loading resource: res://src/client/menu/Chat.gd
Loading resource: res://src/client/VisibleCanvasLayer.gd
Loading resource: res://src/client/menu/ChatPreview.gd
Loading resource: res://src/client/menu/ConnectMenu.gd
Loading resource: res://src/Entry.gd
Loading resource: res://src/client/menu/GameHUD.gd
Loading resource: res://src/client/Main.gd
Loading resource: res://src/client/maps/test-tilemap.tscn
Loading resource: res://icon.png
Loading resource: res://src/client/Player.tscn
Loading resource: res://src/common/TileColissionShape.tres
Loading resource: res://src/client/Player.gd
Loading resource: res://src/common/Player.gd
Loading resource: res://src/server/Main.gd
Loading resource: res://src/server/maps/test-tilemap.tscn
Loading resource: res://src/server/placeholder.jpg
Loading resource: res://src/server/Player.tscn
Loading resource: res://src/server/Player.gd
Loading resource: res://src/Entry.tscn
================================================================
handle_crash: Program crashed with signal 11
Engine version: Godot Engine v3.4.4.stable.official (419e713a29f20bd3351a54d1e6c4c5af7ef4b253)
Dumping the backtrace. Please include this when reporting the bug on https://github.com/godotengine/godot/issues
[1] /lib/x86_64-linux-gnu/libc.so.6(+0x38920) [0x7f68f8a41920] (??:0)
[2] /home/monix/Software/godot() [0x2b8dc21] (??:0)
[3] /home/monix/Software/godot() [0x2b92b36] (??:0)
[4] /home/monix/Software/godot() [0xdea1ee] (??:0)
[5] /home/monix/Software/godot() [0x2b77b5e] (??:0)
[6] /home/monix/Software/godot() [0x2c01745] (??:0)
[7] /home/monix/Software/godot() [0xaab8c4] (??:0)
[8] /home/monix/Software/godot() [0xa3aa60] (??:0)
[9] /home/monix/Software/godot() [0x2b77b5e] (??:0)
[10] /home/monix/Software/godot() [0x2c01745] (??:0)
[11] /home/monix/Software/godot() [0xaab8c4] (??:0)
[12] /home/monix/Software/godot() [0xa3aa60] (??:0)
[13] /home/monix/Software/godot() [0x2b77b5e] (??:0)
[14] /home/monix/Software/godot() [0x2c01745] (??:0)
[15] /home/monix/Software/godot() [0xaab8c4] (??:0)
[16] /home/monix/Software/godot() [0xa3ab20] (??:0)
[17] /home/monix/Software/godot() [0x1d6d53f] (??:0)
[18] /home/monix/Software/godot() [0x1d8c846] (??:0)
[19] /home/monix/Software/godot() [0x1db11ad] (??:0)
[20] /home/monix/Software/godot() [0x9d8c27] (??:0)
[21] /home/monix/Software/godot() [0x9471ad] (??:0)
[22] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xcd) [0x7f68f8a2c7fd] (??:0)
[23] /home/monix/Software/godot() [0x95ae1e] (??:0)
-- END OF BACKTRACE --
================================================================
OS: Debian testing
Godot Version: 3.4.4
Discord is open during the crash.
Hello! I've been trying to integrate this into a project of mine. The thing is, I'm having trouble with figuring out how to integrate it. I've looked at the example authenticate.gd file, but it doesn't seem to be doing what I want it to do.
I just want to make it so that I can use my application ID and display the "playing a game" activity status in Discord. Any help would be greatly appreciated!
Hi ๐,
this addon is missing a license which technically means others aren't allow to use/modify it. This effects the license validity of other plugins that may make use of this plugin such as: 3ddelano/godot-editor-discord-presence#5
res://addons/Discord RPC/ipc/pipe/UnixPipe.gd:(3,12)
+ res://addons/Discord RPC/ipc/pipe/UnixPipe.gd:(6,13)
https://github.com/Abdera7mane/Discord-RPC-GDScript/blob/ba5db0ca46ec8292ea22ab60455ec037ef74322b/addons/Discord%20RPC/ipc/pipe/UnixPipe.gd#L3-L6
It would be nice to have this plugin listed in Godot AssetLib as currently there are no proper plugins for Discord RPC for Godot 3 in the AssetLib.
In Godot 4.2.1
const Payload := DiscordRPCConnection.Payload #Line 656
Error:
Linia 656:Error while getting cache for script "res://discord-rpc/DiscordRPCConnection.gd".
Linia 656:Assigned value for constant "Payload" isn't a constant expression.
Linia 706:Class "UpdateRichPresencePayload" hides a global script class.
I've implemented this project into my game built with Godot 3.5.2, running it on Linux works perfectly fine at works great! But whenever i try running the game on windows it errors out and gives me errors 51 and i was wondering what it meant?
this is the relevant code in case i just completely missed something
func _ready() -> void:
add_child(discord_rpc)
discord_rpc.connect("rpc_error", self, "_on_discord_error")
discord_rpc.connect("rpc_ready", self, "_on_discord_ready")
discord_rpc.establish_connection(APPLICATION_ID)
func _on_discord_error(error: int) -> void:
print("RPC Connection ERROR: ", error)
func _on_discord_ready(user: Dictionary) -> void:
print("yay")
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.