.NET Wrapper or Irrlicht .NET CP? See last post by me...

Irrlicht.Net is no longer developed or supported, Irrlicht.Net Cross Platform is a much more complete wrapper. Please ask your C# related questions on their forums first.
Locked
LennardF1989
Posts: 7
Joined: Sat Jun 09, 2007 4:59 pm
Location: the Netherlands
Contact:

.NET Wrapper or Irrlicht .NET CP? See last post by me...

Post by LennardF1989 »

Hi all,

I'm Lennard Fonteijn from the Netherlands and I'm a quite advanced programmer in a lot of languages (also web)... Though, since I only have a little developers experience, I want to join such a project.

That project only uses a Q3 Engine, which is just old and quite hard to understand and manipulate. So, I have to confince them that Irrlicht is better to handle (spawning objects, levels, etc... We just have to write some kind of scripting language), anyway, I got a couple of questions about Irrlichts doings.

Here he goes:
- When I load a BSP map (from Q3), can IL already parse codes like spawnpoints and triggers (ie: for doors), or do I have to parse that on my own (which means that IL only parses the level)?
- Is it possible to make models solid, so the can't go through other models (like in a BSP level)?
- Is it possible to determine if a model gets hit by something, and also the place of impact?

Also, I've been also experimenting with Irrlicht, that's how I came up with these questions. Because when I spawned a model in a BSP map and moved it around it could walk through other spawned object, which means nothnig is really solid.

Also, I couldnt really think of a way to determine if a model got hit...

Best regards,
Lennard Fonteijn

Ps. If someone has an answer and also knows a way to do it, then hes description (it doesnt have to real detailed) on it will be welcome.
Last edited by LennardF1989 on Thu Jun 14, 2007 10:02 pm, edited 2 times in total.
Yes, I'm writing a VB.NET GameEngine based upon Irrlicht... So what?
Dances
Posts: 454
Joined: Sat Jul 02, 2005 1:45 am
Location: Canada
Contact:

Re: BSP/Model question... Solid models?

Post by Dances »

LennardF1989 wrote:Hi all,

I'm Lennard Fonteijn from the Netherlands and I'm a quite advanced programmer in a lot of languages (also web)... Though, since I only have a little developers experience, I want to join such a project.

That project only uses a Q3 Engine, which is just old and quite hard to understand and manipulate. So, I have to confince them that Irrlicht is better to handle (spawning objects, levels, etc... We just have to write some kind of scripting language), anyway, I got a couple of questions about Irrlichts doings.

Here he goes:
- When I load a BSP map (from Q3), can IL already parse codes like spawnpoints and triggers (ie: for doors), or do I have to parse that on my own (which means that IL only parses the level)?
- Is it possible to make models solid, so the can't go through other models (like in a BSP level)?
- Is it possible to determine if a model gets hit by something, and also the place of impact?

Also, I've been also experimenting with Irrlicht, that's how I came up with these questions. Because when I spawned a model in a BSP map and moved it around it could walk through other spawned object, which means nothnig is really solid.

Also, I couldnt really think of a way to determine if a model got hit...

Best regards,
Lennard Fonteijn

Ps. If someone has an answer and also knows a way to do it, then hes description (it doesnt have to real detailed) on it will be welcome.
Irrlicht does not parse that kind of stuff.
Irrlicht supports basic collision, which will do what you want, have a look at the Collision tutorial for code.
For the 3rd... you can determine when it is hit but not always what hit it. Not where either. You can use multiple bounding boxes to get an idea of where the hit was, though (ie. head box, arm box, etc.).

At least, thats all to the best of my knowledge, anyway.
LennardF1989
Posts: 7
Joined: Sat Jun 09, 2007 4:59 pm
Location: the Netherlands
Contact:

Post by LennardF1989 »

Thanks, for the reply, I like the boxes idea (what kind of boxes you suggest? Just some kind of invisible model?) and I'll take a look at the Collision tutorial.

But, what do you suggest I do about movable doors and walkable stairs in a level? Is a .irr capable of doing that or do i have to load a BSP and fill in the doors by code (and at triggers and stuff, like through a script)?

Regards

Ps. Sorry when the questions are kind of lame, but I only have a bit of Developers experience which I hope I can extend now.

Edit:
Ok, I fuzzled around with the collision a bit, but I still don't understand how this will help me making models solid... It's a multiplayer game, and people shouldn't walk through eachother (also not through placed objects)
Yes, I'm writing a VB.NET GameEngine based upon Irrlicht... So what?
Dances
Posts: 454
Joined: Sat Jul 02, 2005 1:45 am
Location: Canada
Contact:

Post by Dances »

I've never actually done the multiple bounding boxes but I think smgr->addCubeSceneNode would work just fine, then you don't have to have a special 3d model, and you're lower of file size, too.

I've NEVER worked with .irr so I really don't know anything about that. I would think you could edit your DLL to make it work however you like. If you're not keen on that I think it would be easy to have a .irr level and a .xml entity file.

These two threads should also help with your collision as well...
http://irrlicht.sourceforge.net/phpBB2/ ... hp?t=21596
http://irrlicht.sourceforge.net/phpBB2/ ... hp?t=21779
LennardF1989
Posts: 7
Joined: Sat Jun 09, 2007 4:59 pm
Location: the Netherlands
Contact:

Post by LennardF1989 »

Thanks for the links, I'll read through them, since they look interesting...

I looked a bit through them, but as far as i understand is such a bounding box for the whole model, but I need different hit locations (like hand, lower arm, upper arm etc)... Is that also possible to do, or do I need to use a Physics SDk in such a occasion?

Also, the bounding boxes can also be used to determine if someone is trying to walk through something/someone right?

Edit:
ok, I looked around a bit more, and it seems that the Irrlicht ray can be used for determining hitlocations, ie. The nodeid of a hitbox.... (right?)
So now I need a way attach multiple hitboxes on specific parts of the animated model.

Edit 2:
I'm busy with some kind of scriptparser in use with a BSP file, but I was wondering, when I load a BSP in Irrlicht without changing the mesh hes position, will the coordinates still be the same as in the Radiant? Like when I put a spawnpoint on 0,0,0, then it's 0,0,0 in irrlight too.
Yes, I'm writing a VB.NET GameEngine based upon Irrlicht... So what?
Dances
Posts: 454
Joined: Sat Jul 02, 2005 1:45 am
Location: Canada
Contact:

Post by Dances »

Yes, the bounding boxes can be used to check model to model collision.

To attach multiple hitboxes to a model I *THINK* you could make a bunch of CubeSceneNodes as children to the model's node and make the cube scene nodes invisible but collidable. However, it may be that because they are children they wont collide propely... in which case you would have to 'attach' the cube scene nodes with code and make the mesh's node a child of a box... which is a little more work.

As for co-ordinants in Radiant to Irrlicht, yes, they should correspond exactly.
LennardF1989
Posts: 7
Joined: Sat Jun 09, 2007 4:59 pm
Location: the Netherlands
Contact:

Post by LennardF1989 »

Ok, thanks for your support, one last question though,

How exactly would I glue the Cubes on the model if I don't use them as childrens of the model node...

Say I want a box surrounding the head and one surroundig the rest of the body which also moves with the model (ie. Walking)... How would I do that, could you give me an example in case of the female md2 mesh included with Irrlicht...

Edit: If it's a lot of work, a small snippet code is enough too, the part I'm interested in is attaching the cube on the right spot of the model (ie. The head).

Furthermore, since the coords are the same in irrlicht as in GtkRadiant, I'm going to continue the scriptparser for external BSP entities...
Yes, I'm writing a VB.NET GameEngine based upon Irrlicht... So what?
Dances
Posts: 454
Joined: Sat Jul 02, 2005 1:45 am
Location: Canada
Contact:

Post by Dances »

If you don't use the cubes as children you would have to get the position of the model every frame and update the position of your cubes accordingly. Something like:

vector3df p = node->getPosition();
p.Y = p.Y +10;
node2->setPosition(p);

Having them as children would be much easier, but I'm not sure whether collision will take into account their position or their absolute position.
LennardF1989
Posts: 7
Joined: Sat Jun 09, 2007 4:59 pm
Location: the Netherlands
Contact:

Post by LennardF1989 »

Thanks, will try it out... But I realy need the Collision-check and that has to be proper and accurate, so I think the only way left is making all kind of parentnodes, instead of one parent and a lot of children.

But like I sad, I'll try both ways out.

Btw. If I use them as children, would that mean, I only have to update the parent node position?
And what about animation, say someone runs, then hes legs will go forth and back, how would I glue the hitbox to it then? Something like a NodeBox and then make the modelmesh hes parent, that way the childrens get updates automaticly right?

Sorry for the question bomb all the time, but I think I'm starting to get most of the things.

Regards

Ps. I really appreciate your help, thanks.
Yes, I'm writing a VB.NET GameEngine based upon Irrlicht... So what?
Dances
Posts: 454
Joined: Sat Jul 02, 2005 1:45 am
Location: Canada
Contact:

Post by Dances »

Yes, every time you update the parent's position the others will follow on their own.

As for following animated legs... perhaps you should try attaching the Bounding Box (the CubeSceneNode) to one of the models' bones? Then it should follow it nicely.
LennardF1989
Posts: 7
Joined: Sat Jun 09, 2007 4:59 pm
Location: the Netherlands
Contact:

Post by LennardF1989 »

Thanks, then I think all my questions accoring to models are finished...

Perhaps a bit offtopic, but what will be better to use

Irrlicht .NET Wrapper or the Irrlicht .NET CP Wrapper?
And are there any know .NET wrappers for IrrKlang and IrrNet?
Yes, I'm writing a VB.NET GameEngine based upon Irrlicht... So what?
Dances
Posts: 454
Joined: Sat Jul 02, 2005 1:45 am
Location: Canada
Contact:

Post by Dances »

Someone else will have to answer those, I don't use .net.... anyone?
LennardF1989
Posts: 7
Joined: Sat Jun 09, 2007 4:59 pm
Location: the Netherlands
Contact:

Post by LennardF1989 »

What would be better to use:

Irrlicht .NET Wrapper or the Irrlicht .NET CP Wrapper? Arguments?

And are there any know .NET wrappers for IrrKlang and IrrNet?
Yes, I'm writing a VB.NET GameEngine based upon Irrlicht... So what?
Kimundi
Posts: 11
Joined: Sun Apr 01, 2007 11:04 am

Post by Kimundi »

Use the Cp wrapper, it is much better than the official irrlicht wrapper.
Image
[Sorry for possible bad English]
Locked