// SONIC ROBO BLAST 2 //----------------------------------------------------------------------------- // Copyright (C) 1998-2000 by DooM Legacy Team. // Copyright (C) 1999-2014 by Sonic Team Junior. // // This program is free software distributed under the // terms of the GNU General Public License, version 2. // See the 'LICENSE' file for more details. //----------------------------------------------------------------------------- /// \file p_fab.c /// \brief some new action routines, separated from the original doom /// sources, so that you can include it or remove it easy. #include "doomdef.h" #include "g_game.h" #include "p_local.h" #include "m_random.h" static void Translucency_OnChange(void); /** \brief cv_translucency console variables to turn on and off translucency */ consvar_t cv_translucency = {"translucency", "On", CV_CALL|CV_SAVE, CV_OnOff, Translucency_OnChange, 0, NULL, NULL, 0, 0, NULL}; /** \brief Reset Translucency */ static boolean resettrans = false; /** \brief The R_SetTrans function Set the translucency map for each frame state of mobj \param state1 1st state \param state2 last state \param transmap translucency \return void */ static void R_SetTrans(statenum_t state1, statenum_t state2, transnum_t transmap) { state_t *state = &states[state1]; do { state->frame &= ~FF_TRANSMASK; if (!resettrans) state->frame |= (transmap<