Using CCPhysicsBody?

I want to get into physics with CocosSharp. I was about to use CCPhysicsBody in my PCL project, however it's not available in the namespace "CocosSharp".

Checking my NuGet packages (CocosSharp.PCL.Shared), the last package publish date is two years old. Do I miss CCPhysicsBody, because my packages are too old? Why there is no up2date package then?


  • MatExMatEx NLMember ✭✭

    Hi, although I'm not 100% of this, but the issue might be that the dll that you use doesn't contain the CCPhysicsBody - simply because it wasn't compiled into it. Why? Because if you take a look at the CCPhysicsBody.cs file in the CocosSharp GitHub repository (I can't give you the link, because being new here, the forum rules don't let me post links yet) you can see, that there's a preprocessor directive in this file. So basically if you compile the code without specifying this USE_PHYSICS directive, it won't be in the end result.
    Maybe you can compile it for yourself? I dunno

  • modiXmodiX USMember ✭✭
    edited November 2017

    @NetOnJM said:
    If you want play with CCPhysicsXX you will need to compile the nuget with the DebugPhysics user configuration selected.

    It was in a very early stage with some issues pending to fix... but it worked! :-)

    Thanks for this information. I wasn't able to find any information about this on the internet. Why not simply providing a pre-release package of CocosSharp that includes all the experimental features like physics? I love using NuGet packages for its simplicity ...

Sign In or Register to comment.