first small tests for a tram simulator

Announce new projects or updates of Irrlicht Engine related tools, games, and applications.
Also check the Wiki
kcornels
Posts: 11
Joined: Mon Jul 23, 2007 5:40 pm
Location: Germany

Post by kcornels »

Hi,

first new test, and the problems are beginning :-)

Image

This object uses different material. One should be transparent (with light reflections) one should be very reflective (brushed steel). Unfortunately I can only set the material style for the whole object, not just for one material... .

OK, I guess, I will have to look a bit more in the docu... .
Strong99
Admin
Posts: 687
Joined: Fri Mar 31, 2006 7:06 pm
Location: Netherlands
Contact:

Post by Strong99 »

who nice :P
very nice textured.

myNode->getMaterial( number )->setFlag( set your parameters :P transparant )
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

You did not tell, yet, which 3d modeller and file format you use. But it would be the best if you change the materials there.
kcornels
Posts: 11
Joined: Mon Jul 23, 2007 5:40 pm
Location: Germany

Post by kcornels »

Hi,

OK, it works now... .

Coming mainly from Delphi and C# I guess, i have to think a bit more in pointers now... :roll:

Image

edit: now with skybox and reflections on the metall faces and the glass... .
Last edited by kcornels on Sat Jul 28, 2007 11:56 am, edited 2 times in total.
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

That is really awesome, have you thought about using parallax mapped material for the floors yet? Now that you know how to set a different material for different things...
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Midnight
Posts: 1772
Joined: Fri Jul 02, 2004 2:37 pm
Location: Wonderland

Post by Midnight »

I just keep thinking to myself... why all this effort for a freaking tram simulator... I mean trams are so exciting... is this for a job or something??
kcornels
Posts: 11
Joined: Mon Jul 23, 2007 5:40 pm
Location: Germany

Post by kcornels »

hmm,

I like trams, so I'm doing a "freaking" tram sim... .

Other people may prefer games with shooting at people, but I like diving with trams... .
vermeer
Posts: 2017
Joined: Wed Jan 21, 2004 3:22 pm
Contact:

Post by vermeer »

it's weird and curious.
;)
Looking very good.
Yeah I agree the floor could use some parallax mapping Twisted Evil (Theres a tool that lets you generate normals maps from ordinary textures if I remember correctly, else just grayscale it and it should have a similar effect if you tweak it right.)

Which tool? A Photoshop plugin?
Parallax, normal maps, often require extra hi res modelling...tho I understand you refer some sort of hack..dunno if that gets convincing...I model hi res with no probs, just yet haventplayed with real time normals, paralaps in any engine...well, I did, but not long experience.


is not only the textures: the models are good too :)

Keep at it. :)

I've done work in that sort of content, too..... ;)
and when u'r doing it in 3d, with not yep populating with characters, has a sort of feel of lone place, with its magic... (lol, ideal for thieves ;) )
I documented my self a lot for the task... machines around all world, but centered in certain city...

Good luck, building the whol station is a tad of work, but a very good exercise!
Finally making games again!
http://www.konekogames.com
vermeer
Posts: 2017
Joined: Wed Jan 21, 2004 3:22 pm
Contact:

Post by vermeer »

oh, and yes, you better setup reflection maps..in this case are very needed...
and nice gi lightmaps are essential need.

You may wanna try with b3d format, already support those. (ref maps I dunno how it goes, guess is all engine stuff in that case)

heck, Blender is making royal progress in the baking solutions...really eager to make some working level sample with Blender->b3d format->irrlicht.
Finally making games again!
http://www.konekogames.com
pinballwizard
Posts: 67
Joined: Wed Aug 02, 2006 1:47 am

Post by pinballwizard »

Midnight wrote:I just keep thinking to myself... why all this effort for a freaking tram simulator... I mean trams are so exciting... is this for a job or something??
You might be surprised at how popular these kind of games are in some parts of the world. For example, see http://en.wikipedia.org/wiki/Let's_Go_by_Train .

To the original poster: keep up the good work. Are you planning on adding a physics simulator, so you can slam the train into the wall and watch the passengers' limp bodies go flying? :twisted:
kcornels
Posts: 11
Joined: Mon Jul 23, 2007 5:40 pm
Location: Germany

Post by kcornels »

Hi,

currently I'm slowly running into some kind of frustration... :-(.

I've tried to get animations (exported by the panda exporter for max5 ) to work in irrlicht.

I can export my modells with the animation woking fine in mview. But in Irrlicht no animation is played and/or the different parts of the model are completely disorted in space ... . Saving the model from mview does not really provide any help... .

Is there any idiot proof solution to this problem ?
vermeer
Posts: 2017
Joined: Wed Jan 21, 2004 3:22 pm
Contact:

Post by vermeer »

It's usual issue with x...long time ago there wasnt other so mamny weights and bones formats out there...today, ha smore sense to use b3d and md5. With irrlicht, seem to be having a lot of sense to use b3d now.

But you use max for all, it seems. Otherwise I'd say now a way less painful to get anims into irrlicht is using blender and b3d exporter:
http://gandaldf.altervista.org/b3dexporter.htm

...but if you're using Max5, I am pretty sure there's a perfectly working b3d free exporter for it. There's not for Max 9, I think.

And a pitty you don't have Ultimate Unwrap (unwrap3d.com): my painless way with max was allways exporting with the Unwrap3d free plugin for Max (*.u3d files get exported) , load the *.u3d in Ultimate Unwrap (unwrap3d as i call it) , make some change there if feel is needed, export as b3d file. Works like charm, no issues, no werid setting, no nothing. And the possibility of edits in Unwrap3d is big.I purchased, so I allways have the latest one.

This is imo one of the best way for b3d and max users, as Unwrap3d author keeps maintaining both b3d format and max plugin...It forces to export everything from max, as an *.u3d file.

Of course, for Blender users, best way is the mentioned b3d plugin.

I really would like if b3d can get lightmaps(btw, you're not doing lightmaps, do you? If they're made with good GI lighting , adds a lot of ambience and realism...lighting is crucial in a scene...) exported from blender, but unsure if there's some internal code addition needed for the plugins to export that uv and material data...

about the x issue, sure has a solution. Every 3 months passed I forget more and more of the needed tricks, as I made the full trial for once and everybody which had issues with it...there's a ton of things to consider...

specially panda has many settings...
Try to have the stack as more simple as possible before export...
the right handed, or left handed system settings, try the opposite...
Are you suing biped or bones..is all about bones...there's a way to convert biped to bones...mainly export as fbx at the very end, and reimport, then export as x...
i think you had to use ascii, and srt instead of matrix...
Did you mirored or scaled in a bad way the bones to build the skeleton? that'd ruin the exported x.
some transform making something weird internally...
try to not use multisuobjects materials, but standard ones...no material names starting with numbers, neither bones names with "." or "_" nor I thik spaces, in them....
I hope you didnt have vertices unweighted or unasigned in ytour scene...and that you may ensure (sometimes an stl check *before* riging the mesh is a great idea, to check for not noticeable errors.)

Hum.
re-reading how u describe the issue, reminds me of ...some hierarchy prob...be sure there's one root in the scene and all pending from it, and that you did set the correct hierarchy setting in Panda.(something talking bout root bone parent of all...)
Or some bones bad connected or something...
Oh, and forgot: better if you do all model as one piece, not separate pieces, just attached, but welded at vertex level... Several parts meshes in a bone hierarchy can cause that problem you say...

My advice, ensure this all in a more basi mesh export, rigged and all,with not many weird stacks and Max effects. So youc an determine what you are doing wrong.
The faster way is just test those offending files but checking all what I mention and fixing what is neeeded, and try to exprot. Beware the amtter on if ur using biped or not is important...also, the fbx i/o trick may or may not work with max5...in max6 works for very sure...

And best advice: switch to b3d format is it's possible for you.
Finally making games again!
http://www.konekogames.com
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

There's also always the possibility to send in meshes (either publically through the forum or directly via PM) such that the developers can have a look at issues with .x format. Luke is currently updating the ,x loader for the new animation system, so there's another refactoring going on. A good point to provide more enhancements...
But (don't know about the new system, but for now), .x is pretty slow compared to .b3d and .ms3d files. So changing the file format might still be a good thing.
kcornels
Posts: 11
Joined: Mon Jul 23, 2007 5:40 pm
Location: Germany

Post by kcornels »

Hi,

Many thanks for your lengthy answers :-)

I've tried the B3D Pipeline Exporter. I showed a wonderfull animated object :D in the B3D-Viewer, but unfortunately no sign of an animation in Irrlicht... .

I'm sure there must be a way, somehow... .

I've exported a simple block, which rotates around the z-axis by the help of two keyframes... .

If I export the modell, the B3D Viewer shows the correct animation and in a modell overview he correct animation frames... .

After loading in Irrlicht I see the mesh, but no animation.

Code: Select all

IAnimatedMesh* mesh = smgr->getMesh("tw2000/tw2000.x");
IAnimatedMesh* trittmesh = smgr->getMesh("tw2000/trittstufe.b3d");
IAnimatedMeshSceneNode* node = smgr->addAnimatedMeshSceneNode( mesh );
IAnimatedMeshSceneNode* tritt1 = smgr->addAnimatedMeshSceneNode(trittmesh,node);
tritt1->setMaterialFlag(EMF_LIGHTING, true);
tritt1->setMaterialType(video::EMT_SOLID);
tritt1->setPosition(core::vector3df(0,0,2.19));
tritt1->setAnimationSpeed(30);
tritt1->setLoopMode(true);
edit: I managed to load the object into blitzbasic (welcome to the wonderfull world of 30 day demo versions) and the animation is playing... .
Last edited by kcornels on Wed Aug 08, 2007 1:12 pm, edited 1 time in total.
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Try to increase the framerate to 3000 (IIRC the frames are multiplied by 100 for smoother interpolation). This won't be needed with the new animation system anymore, so it's just a temporary hack!
Post Reply