Giter Club home page Giter Club logo

Comments (6)

mayuki avatar mayuki commented on June 18, 2024

MSBuild.Task is no longer supported in MagicOnion 5.x.
MessagePack Formatter error may be due to the Resolver not registered.

https://github.com/Cysharp/MagicOnion/blob/release/5.x/README.md#messagepack-for-c-1

from magiconion.

wmqKevin avatar wmqKevin commented on June 18, 2024

MSBuild.Task is no longer supported in MagicOnion 5.x. MessagePack Formatter error may be due to the Resolver not registered.

https://github.com/Cysharp/MagicOnion/blob/release/5.x/README.md#messagepack-for-c-1

Thank you @mayuki

the problem was solved after I manually added it. However, when I declare a function, if there are multiple parameters, MagicOnion will generate the corresponding DynamicArgumentTuple, but I haven't found a way to automatically generate the corresponding Formatter. Can it be generated automatically?

from magiconion.

mayuki avatar mayuki commented on June 18, 2024

If code is generated by generator, it will automatically generate the corresponding Formatter for the argument.
https://github.com/Cysharp/MagicOnion/blob/release/5.x/samples/ChatApp/ChatApp.Unity/Assets/Scripts/Generated/MagicOnion.Generated.cs#L148

from magiconion.

wmqKevin avatar wmqKevin commented on June 18, 2024

If code is generated by generator, it will automatically generate the corresponding Formatter for the argument. https://github.com/Cysharp/MagicOnion/blob/release/5.x/samples/ChatApp/ChatApp.Unity/Assets/Scripts/Generated/MagicOnion.Generated.cs#L148

Thank you @mayuki
I looked at the content of "ChatApp.Shared.csproj" and solved the problem, but a new problem has emerged - -.
When my Server serializes UnityEngine.Vector3, a similar FormatterNotRegisteredException error occurs. I tried to register it in the Resolver using the MagicOnionResolver in Unity, but it seems to have no effect.
image
Is there any way to register Unity's data structures on the server side, or do I need to define new structures myself?

from magiconion.

mayuki avatar mayuki commented on June 18, 2024

On the server side, need to install/use the MessagePack.UnityShims package.
https://github.com/MessagePack-CSharp/MessagePack-CSharp?tab=readme-ov-file#unity-support

from magiconion.

wmqKevin avatar wmqKevin commented on June 18, 2024

On the server side, need to install/use the MessagePack.UnityShims package. https://github.com/MessagePack-CSharp/MessagePack-CSharp?tab=readme-ov-file#unity-support

Thank you!
It works!

from magiconion.

Related Issues (20)

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.