Coder Social home page Coder Social logo

discord-game-sdk-test-apps's People

Contributors

msciotti avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

discord-game-sdk-test-apps's Issues

RegisterCommand not working

In the given example tried adding following code in the main.cpp before UpdateActivity to set the game launch link
state.core->ActivityManager().RegisterCommand("chrome.exe https://google.com"); and
state.core->ActivityManager().RegisterCommand("https://google.com");

Neither of above command worked to reflect the game launch link in the users rich presence. Does the registerCommand support http or https protocol?

Unity: Error when running unity example build with IL2CPP

I'm getting the following runtime error when running a compiled IL2CPP build using Unity 2018.2.21f1.

NotSupportedException: IL2CPP does not support marshaling delegates that point to instance methods to native code. at System.Runtime.InteropServices.Marshal.StructureToPtr[T] (T structure, System.IntPtr ptr, System.Boolean fDeleteOld) [0x00000] in <00000000000000000000000000000000>:0 at Discord.ActivityManager..ctor (System.IntPtr ptr, System.IntPtr eventsPtr, Discord.ActivityManager+FFIEvents& events) [0x00000] in <00000000000000000000000000000000>:0 at Discord.Discord.GetActivityManager () [0x00000] in <00000000000000000000000000000000>:0 at DiscordController.Start () [0x00000] in <00000000000000000000000000000000>:0

License?

Under what license is the code of this repository?

Update DiscordController.cs with CreateFlags explanation

Hi, thank you for the sample apps. I was wondering if it would be good to update the Unity example with these comments from the starter guide. Personally I was very surprised that closing your game is the default behavior if discord can't be started, even with a try/catch (tested on ubuntu), so it's good to make this clear to save people some time. I wonder what the use case is for a game requiring Discord to start, but using the other flag is easy enough.

https://discord.com/developers/docs/game-sdk/sdk-starter-guide

/*
    Grab that Client ID from earlier
    Discord.CreateFlags.Default will require Discord to be running for the game to work
    If Discord is not running, it will:
    1. Close your game
    2. Open Discord
    3. Attempt to re-open your game
    Step 3 will fail when running directly from the Unity editor
    Therefore, always keep Discord running during tests, or use Discord.CreateFlags.NoRequireDiscord
*/
var discord = new Discord.Discord(CLIENT_ID, (UInt64)Discord.CreateFlags.Default);

Thank you

What platforms is it for?

Hi, Thank you very much for this demo as it was the only way for me to get discord SDK!

I have a question about what platforms is this SDK for and is it possible to be used for WebGL. I tried it and it did not work is there something that I can do to make it work?

Compiler errors within discord sdk

I get two compiler errors after importing the sdk, they're all within the sdk:
Assets\Plugins\DiscordGameSDK\Core.cs(3492,17): error CS0019: Operator '!=' cannot be applied to operands of type 'bool' and 'Result'

Assets\Plugins\DiscordGameSDK\Core.cs(3494,43): error CS1503: Argument 1: cannot convert from 'bool' to 'Discord.Result'

Unity 2020.3 and latest GameSDK Linux 64bit

(System.UInt64)Discord.CreateFlags.Default
If run in editor, editor crash
If build and run game, game crash

(System.UInt64)Discord.CreateFlags.NoRequireDiscord
Game not detected and SDK not effect game.

Operating System: Ubuntu 21.04

<game> is not detected

Hello,

Using the latest SDK (as of 02 Dec 2019) I'm trying to integrate invite/join function but the game is not detected unless I open it manually.
I've found this issue and I still think that it is not resolved:
discord/discord-rpc#238

Can you please suggest any workarounds/fixes for this?
Do I need to have the game page published (for testers or alpha)?
I have the registry key set and I can launch the game with URL:
discord-:// from the browser, but it takes couple of seconds (which is strange)

Thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.