Well I found the ESC+m to work well. If you run the game under debug and load a map, you get to update the map in the editor and then run game after?
So I found the "coll=1" in the level configs, but changing it for my mesh didn't work.
I made a box mesh in the obj file with a model editor to see if a triangle selector was made when the level loads, but that didn't work, plus it ruined other textures.
I tried finding any collision check boxes in the editor but I couldn't find any.
I deleted the folder and I'll start it again. All I did was rename one of the bodged tracks and could have easily renamed it :-/
The editor was okay. As long as you load a level first. I likened the models/nodes to the bigger engines Project Files window. Some text in the GUI was hidden for physics, but the rest of it was good.
I was a bit lost with the code because it does indeed go from bottom up. All the little details build on top of each other, but I still couldn't find where collision gets made.
H-Craft new mesh doesn't find collision
Re: H-Craft new mesh doesn't find collision
Sorry, was my first app with Irrlicht and I wasn't yet that experienced back then. There is no flag - simply the main mesh for a level is a single mesh and collides. Nothing else does - every other object is just graphical effects. Done by IrrlichtManager::LoadModel which is called by Level::Load from what I can see. Collision handling should then be in the physics file.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Re: H-Craft new mesh doesn't find collision
Technically I'd be writing my own mesh collider then?
It is good to see how a racer game is made. If I look at my history of coding, I get this...
It's hardly grand wizardry.
(oh, the physics are actually amazing. I could see Cool Boarder 3 like tricks)
It is good to see how a racer game is made. If I look at my history of coding, I get this...
Code: Select all
float player_x += gravity * speed * deltaTime; // blah blah
(oh, the physics are actually amazing. I could see Cool Boarder 3 like tricks)
Re: H-Craft new mesh doesn't find collision
I did see the track walls? It looks like they are boxes that stop the player falling off. I'll take that into consideration. Hope you're okay.
Re: H-Craft new mesh doesn't find collision
Ah yes, I added those track walls later (when I did Android port). Original release didn't have them (and people complained about falling off track non-stop). They likely have their own collision.
We really need some more simple game examples. The shortest game with Irrlicht I made is probably this one: https://github.com/mzeilfelder/irr-play ... vaders.cpp
But likely that is then too simple (no loading of media whatsoever and not using Irrlicht's collisions system). And probably not the best code (globals all over the place). But I think it's kinda one of the smallest games one can do, so for a start it might be easier to look at that.
We really need some more simple game examples. The shortest game with Irrlicht I made is probably this one: https://github.com/mzeilfelder/irr-play ... vaders.cpp
But likely that is then too simple (no loading of media whatsoever and not using Irrlicht's collisions system). And probably not the best code (globals all over the place). But I think it's kinda one of the smallest games one can do, so for a start it might be easier to look at that.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm