### Looking for testers for C#

Moderator: andrewmac

#### Looking for testers for C#

LukasPJ
Posts: 358
Joined: Tue Feb 03, 2015 7:25 pm

Hey guys, I just uploaded a C# project, that allows you to embed Torque6 into C#. Testing is heavily needed though!
So if you're interested in the project and want to help out, then feel free to download the source here:
https://github.com/lukaspj/Torque6-Embedded-CSharp

It currently depends on this branch (PR pending):
https://github.com/lukaspj/Torque6/tree ... cinterface

Be aware that I haven't gotten around to writing documentation yet, so you have to be a bit independent for now. But the files you'll want to have a look at are the "SampleGame" project and the Torque6.Interop.Attributes class.

Happy hacking!

#### Re: Looking for testers for C#

andrewmac
Posts: 295
Joined: Tue Feb 03, 2015 9:45 pm

I'll have to give this a shot later. All I'd really need is .NET support installed for Visual Studio I imagine?

#### Re: Looking for testers for C#

LukasPJ
Posts: 358
Joined: Tue Feb 03, 2015 7:25 pm

andrewmac wrote:I'll have to give this a shot later. All I'd really need is .NET support installed for Visual Studio I imagine?

Ideally, it should work with either .NET Core and possibly Mono. But it has only been tested with .NET and in Visual Studio

#### Re: Looking for testers for C#

andrewmac
Posts: 295
Joined: Tue Feb 03, 2015 9:45 pm

Just cloned it. Tried to compile in Visual Studio Community 2015 and I get a bunch of errors saying cannot convert from 'string' to 'System.IntPtr' from lines such as this one for example:
https://github.com/lukaspj/Torque6-Embedded-CSharp/blob/master/Torque6/Engine/Namespaces/Audio.cs#L120

Did I miss a step?

#### Re: Looking for testers for C#

LukasPJ
Posts: 358
Joined: Tue Feb 03, 2015 7:25 pm

andrewmac wrote:Just cloned it. Tried to compile in Visual Studio Community 2015 and I get a bunch of errors saying cannot convert from 'string' to 'System.IntPtr' from lines such as this one for example:
https://github.com/lukaspj/Torque6-Embedded-CSharp/blob/master/Torque6/Engine/Namespaces/Audio.cs#L120

Did I miss a step?

Why did it work on my machine? No you did not, the P/Invokes should return IntPtr not strings, e.g.:
internal static extern string Audio_AlGetString(string ALEnum);

I'll look at why it compiles on my machine, then upload a fix

LukasPJ