diff options
Diffstat (limited to 'src/elements')
| -rw-r--r-- | src/elements/graphics_default.c | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/elements/graphics_default.c b/src/elements/graphics_default.c new file mode 100644 index 0000000..d64c0e1 --- /dev/null +++ b/src/elements/graphics_default.c @@ -0,0 +1,22 @@ +#include <element.h> + +int graphics_DEFAULT(GRAPHICS_FUNC_ARGS) +{ + int t = cpart->type; + //Property based defaults + if(ptypes[t].properties & PROP_RADIOACTIVE) *pixel_mode |= PMODE_GLOW; + if(ptypes[t].properties & TYPE_LIQUID) + { + *pixel_mode |= PMODE_BLUR; + } + if(ptypes[t].properties & TYPE_GAS) + { + *pixel_mode &= ~PMODE; + *pixel_mode |= FIRE_BLEND; + *firer = *colr/2; + *fireg = *colg/2; + *fireb = *colb/2; + *firea = 125; + } + return 1; +} |
