I would like to make a 360 game and was just wondering if I could re-use some existing C code I have or whether I need to re-write everything in C#. Any help is appreciated.
2 Answers
Yes and no.
Officially, the only thing you can use on the 360 with XNA is C#. You can't ship any unmanaged DLLs with an app on xbox live, and if you want to write your game in C, you need a dev kit and an impossible-to-get contract with Redmond.
That said, anything you can compile into CIL that will run on the compact framework will be okay. If you can convince your code to compile as managed c++, you should be able to get it to work.
2016 Update
Times have changed. Grab VC++, your off-the -shelf XBONE and go nuts.
Or, better yet -if you're really stuck on C#, which is a pretty great little language - use Unity, or monogame. The former is a complete, really awesome engine and ecosystem, the latter is perfect if you want to roll your own.
-
1\$\begingroup\$ Additionally, you can do just about anything you want from a Windows XNA Game. The requirement of no unmanaged code is XBOX (and WP7) only. \$\endgroup\$– NateMay 25, 2011 at 18:50
-
its better to use C#. bacause that using C# will not cause unknow problems.
however, Yes, it can cll C functions.
-
3\$\begingroup\$ -1 because you didn't really elaborate on any of your points. "unknow [sic] problems": what kind? "can cll [sic]": how? \$\endgroup\$– TetradApr 24, 2011 at 16:39