diff options
author | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2023-06-30 11:44:33 +0200 |
---|---|---|
committer | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2023-06-30 16:52:36 +0200 |
commit | cb2be8723a16f9fdb13582562cb630c945dcd0a7 (patch) | |
tree | 20c0c99c5217792e054f876712a54ae8b4f1eec8 /src/WebRTCLibPeerConnection.cpp | |
parent | d278661d767f5e1f8f68af2d0a706f5f044aa5d3 (diff) | |
download | fork-godot-webrtc-native-cb2be8723a16f9fdb13582562cb630c945dcd0a7.tar.gz fork-godot-webrtc-native-cb2be8723a16f9fdb13582562cb630c945dcd0a7.tar.bz2 fork-godot-webrtc-native-cb2be8723a16f9fdb13582562cb630c945dcd0a7.zip |
Support building for Godot 4.1 (new default).
Diffstat (limited to 'src/WebRTCLibPeerConnection.cpp')
-rw-r--r-- | src/WebRTCLibPeerConnection.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/WebRTCLibPeerConnection.cpp b/src/WebRTCLibPeerConnection.cpp index a372644..effc1d7 100644 --- a/src/WebRTCLibPeerConnection.cpp +++ b/src/WebRTCLibPeerConnection.cpp @@ -180,7 +180,11 @@ Error WebRTCLibPeerConnection::_initialize(const Dictionary &p_config) { return _create_pc(config); } +#if defined(GDNATIVE_WEBRTC) || defined(GDEXTENSION_WEBRTC_40) Object *WebRTCLibPeerConnection::_create_data_channel(const String &p_channel, const Dictionary &p_channel_config) try { +#else +Ref<WebRTCDataChannel> WebRTCLibPeerConnection::_create_data_channel(const String &p_channel, const Dictionary &p_channel_config) try { +#endif ERR_FAIL_COND_V(!peer_connection, nullptr); // Read config from dictionary |