Hi everyone,
Not sure why but I am getting these weird screen effects after creating several decals, the screen effect moves with the sun angle (cause of shadows maybe?). I use shade-c by the way, maybe its cause of the shader I use for the decal? Here are some pics:
My code the spawn the decals:
PARTICLE* p = ent_decal(ent, _bmap, _size + random(_size_random), _rota + random(_rota_random));
p.lifespan = _time;
p.material = mtl_simpleTransparent;
set(p, TRANSLUCENT);
And here is the shader/fx file of the decal:
//------------------------------------------------------------------------------
//----- USER INPUT -------------------------------------------------------------
//------------------------------------------------------------------------------
//assign skins
#define SKIN_ALBEDO (skin1.xyz) //diffusemap
#define SKIN_ALPHA (skin1.w) //alphamap
#define SKIN_NORMAL (skin2.xyz) //normalmap
#define SKIN_GLOSS (skin2.w) //glossmap
//...
#define NORMALMAPPING //do normalmapping?
//#define GLOSSMAP //entity has glossmap?
#define ALPHA //entity has alphamap?
////#define TRANSPARENT //entity alpha should be interpreted as transparent/translucent?
//------------------------------------------------------------------------------
// ! END OF USER INPUT !
//------------------------------------------------------------------------------
#include <scHeaderObject>
//custom code goes here
#include <scObject>