Physics engine + VB6

Started by
5 comments, last by luke88 16 years, 11 months ago
I was wondering if there are any physics libraries that I could use with Visual Basic 6? I know it's unlikely, but there must be something, surely. I searched the Newton forum and someone said it would be possible to use it in VB6 if a C wrapper was made. Unfortunately, I don't know how to do that. (I would ask about it there, but for some reason I can't register). Any help would be greatly appreciated.
luke88
Advertisement
I know this is not going to help much but, if you manage to do the small step up to vb.net you could use an ODE migration to .net. You'd also be able to use XNA to paint what the physics engine calculates.
I would switch to vb.net, but I heard that the differences between that and vb6 are quite significant, and I don't really want to start learning something new just yet.
If I were to switch to vb.net, how would I go about doing the things you mentioned?
luke88
Quote:Original post by luke88
I would switch to vb.net, but I heard that the differences between that and vb6 are quite significant, and I don't really want to start learning something new just yet.

Well, I don't think vb6 is a language prepared to build a complex game, so you'd have to change eventually.
VB.net is a relatively small change (you'd be better changing to C++ or C#.NET) that will prepare you to for the next step.

Quote:Original post by luke88
If I were to switch to vb.net, how would I go about doing the things you mentioned?


Using XNA for graphics shouldn't be too hard. It's not fully supported like in c# case, but most of it is already usable and the rest should come soon.

To use ODE you'd need a .NET wrapper, there are some around. I've used ODE.NET and it worked perfectly. Learning to use ODE (as any physics engine) can be the hardest part of this process but it's unavoidable.
Quote:Original post by Zanshibumi
Well, I don't think vb6 is a language prepared to build a complex game, so you'd have to change eventually.
VB.net is a relatively small change (you'd be better changing to C++ or C#.NET) that will prepare you to for the next step.

Anything I've ever needed to do I could do in vb6. My last project was all vb6.
Quote:Original post by ZanshibumiUsing XNA for graphics shouldn't be too hard. It's not fully supported like in c# case, but most of it is already usable and the rest should come soon.

To use ODE you'd need a .NET wrapper, there are some around. I've used ODE.NET and it worked perfectly. Learning to use ODE (as any physics engine) can be the hardest part of this process but it's unavoidable.

What's XNA?
Would I be able to use ODE in vb.net?

(I did some research and discovered that the differences between vb.net and vb6 are actually quite minor, so I probably will switch. I'm having some problems getting vb.net up and running, though).

luke88
Quote:Original post by luke88
What's XNA?

The XNA Framework is a set of .NET libraries to build games. It's the "Game programming expansion pack" ;).

XNA VB tutorials

Quote:Original post by luke88
Would I be able to use ODE in vb.net?

ODE is in C++. OdeNet is a wrapper in C# (there are many others).

In .NET you can create solutions that contain projects in any .NET language. You'd just need to download the C# OdeNet source, add it to a solution and create a VB.NET project of yourself in the same solution, reference the OdeNet project output and you can access it freely.
It may sound harder than it actually is. Just download source, open with visual studio, create project, add reference.

Quote:Original post by luke88
(I did some research and discovered that the differences between vb.net and vb6 are actually quite minor, so I probably will switch. I'm having some problems getting vb.net up and running, though).


You seem to know what you're doing so my advice is literally:

- Export a simple vb6 project of yours that you know line by line to VB.NET.
- Read the result and poke around a little.
- Read and follow any "XNA for VB.NET" tutorial.
- Create a project that paints something with XNA.
- Download OdeNet, paste it in your painting solution directory, open, rebuild, reference the OdeNet output dll from the VB project.
- Read the most simple tutorial in ODE wiki. Reproduce it with or without visual output, from your VB.NET project.

Here you already have everything you need. Next step could be:

- As soon as you grasp firmly .NET in it's VB form. Try to read C# code. If you can imagine what it's doing (you will), learn C#, export your vb project and then load it all in "XNA Game Developer studio".
- Add C# to your CV.
- Add me to your first C#+XNA+ODE game's credits.
Ok, well thanks for all your help. I'll let you know how it comes along.
luke88

This topic is closed to new replies.

Advertisement