Looking for testers for C#

Moderator: andrewmac

6 posts Page 1 of 1
LukasPJ
Site Admin
Posts: 319
Joined: Tue Feb 03, 2015 7:25 pm
 
by LukasPJ » Mon Apr 25, 2016 8:19 am
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!
andrewmac
Posts: 295
Joined: Tue Feb 03, 2015 9:45 pm
 
by andrewmac » Mon Apr 25, 2016 3:08 pm
I'll have to give this a shot later. All I'd really need is .NET support installed for Visual Studio I imagine?
LukasPJ
Site Admin
Posts: 319
Joined: Tue Feb 03, 2015 7:25 pm
 
by LukasPJ » Mon Apr 25, 2016 8:16 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
andrewmac
Posts: 295
Joined: Tue Feb 03, 2015 9:45 pm
 
by andrewmac » Wed Apr 27, 2016 1:05 am
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?
LukasPJ
Site Admin
Posts: 319
Joined: Tue Feb 03, 2015 7:25 pm
 
by LukasPJ » Wed Apr 27, 2016 8:43 am
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? :o 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 :P
LukasPJ
Site Admin
Posts: 319
Joined: Tue Feb 03, 2015 7:25 pm
 
by LukasPJ » Wed Apr 27, 2016 9:09 am
Just updated it, should be working now!
6 posts Page 1 of 1

Who is online

Users browsing this forum: No registered users and 1 guest