Page 1 of 1

Reflections & collision meshes

Posted: Tue Nov 24, 2009 10:05 pm
by Coroner47
I don't know if ive been sitting infront of the laptop too long today or if i created a bug... but im getting a glassy reflection of the sky in my sniper scope lens. Ive never noticed this before. Am i on glue?

Also, i wanted to add collisions to the helmets & other kitparts of the soldiers. Everything works, but what i did to make the collision more accurate (so you can still shoot ppl in the face) i removed the 6 sided box style collision mesh from the 3d object, cloned the lod object & made it the new col mesh. Question is, is it bad to have a collision mesh with alot of detail? I don't notice any performance drop.

Re: Reflections & collision meshes

Posted: Tue Nov 24, 2009 10:59 pm
by fo0k
I think you may be on glue. lenses are mostly envmapped from what i recall

the collisions.. hmm.. i was under the impression that all models just used the actual player mesh for collision anyway?

Re: Reflections & collision meshes

Posted: Wed Nov 25, 2009 2:16 am
by MR PINK BALLS
helmet can be done tlk to me on xfire

Re: Reflections & collision meshes

Posted: Wed Nov 25, 2009 2:41 am
by fo0k
useful if you post it here :)

Re: Reflections & collision meshes

Posted: Wed Nov 25, 2009 8:29 am
by Coroner47
alright Pinky says this new collision mesh isn't gonna effect the performance of the game & i trust him because he's a smart dude. The question is answered.

Im still confused about this reflection business in my sniper scope though. I can't believe that i haven't noticed this before. It seems to dissapear (spelling? drunk) when i enter into shadowed areas? If this reflection is legit, how can i use it with windows of vehicles & other stuff?

here a video of the reflection in the sniper scope :shock:
http://www.youtube.com/watch?v=3lyccXshBio

Re: Reflections & collision meshes

Posted: Wed Nov 25, 2009 1:38 pm
by fo0k
So environment mapping seems to have escaped you for the past 8 years it seems!

you can add this envmap/reflection to anything.. it is a line of code in the rs file of an object and the amount of reflection is determined by the alpha layer in the texture.

I think even the browning has envmap.. you can see the reflections in the scratches on the gun.

the envmap images are stored in the textures folder of your map prefixed with 'env'. these giv e the appearance of reflections of your surrounding terrain.. but they are not actual dynamic reflections.. just a respresentation.

do you play around with 3d objects etc.. CSM's? maybe why you have missed this... I think 'reflections' as I knew them was one of the first thing i learned when mapping :) can help more if you need it on this.

It dissappears in the shadows intentionally to help things look 'realistic'.. however enmapping does have problems with maps where the 'in shadow darkness' is enabled (its the LightmapShadowBits.lsb file that controls this). sometimes envmapping will vanish in the shadows only to never return when you come back out.. its a bf bug afaik. *just noticed that bug happen in your vid!

check out this vid of some 'extreme' envmapping i did for a chrome landscape :)
http://is82.com/e107_plugins/greygallery/view.php?id=2794
...and all of this presumes you were not aware of how this works.. apologies if I've missed the point.

Re: Reflections & collision meshes

Posted: Thu Nov 26, 2009 8:28 am
by Coroner47
well i must have smoked some crack in my sleep... because i don't recall ever seeing this reflection on the sniper scope lens. Wow! Strange! Maybe i updated my vid card drivers or something. I know ive seen some glassy looking effect on some vehicles which i suppose is this env mapping effect. So can i add this effect to say, a molitov cocktail bottle if i have the alpha layer set to be partially transparent? Would i get a partially transparent bottle & a reflection. Duh i guess i can try myself!