[Include] Easy Screen Fade By OTACON
#5

pawn Код:
/*
   native SetEasyScreenFade(slot,playerid,Text:textdrawid,colour,bool:mode,timer); //para activar un screen fade. mode=false(TextDrawBoxColor)  mode=true(TextDrawColor)
   native KillEasyScreenFade(slot,playerid,Text:textdrawid); //para desactivar un screen fade.
   public OnFunctionOfEasyScreenFade(slot,playerid); //para darle alguna funcion a un screen fade cuando termina el progreso.
*/

#define MAX_SCREEN_FADE (100) //cantidad maxima de screen fade
static DeadlEasyScreenFade[MAX_PLAYERS][MAX_SCREEN_FADE],
EasyScreenFadeStatus[MAX_PLAYERS][MAX_SCREEN_FADE];
forward OnFunctionOfEasyScreenFade(slot,playerid);
forward EasyScreenFadeUpdate(slot,playerid,Text:textdrawid,colour,bool:mode);
public EasyScreenFadeUpdate(slot,playerid,Text:textdrawid,colour,bool:mode){
#define STATUS_FADE (15)
if(!mode){TextDrawBoxColor(textdrawid,colour-(0x11*EasyScreenFadeStatus[playerid][slot]));}
else{TextDrawColor(textdrawid,colour-(0x11*EasyScreenFadeStatus[playerid][slot]));}
if(EasyScreenFadeStatus[playerid][slot]>=STATUS_FADE){
    KillTimer(DeadlEasyScreenFade[playerid][slot]);
    TextDrawHideForPlayer(playerid,textdrawid);
    EasyScreenFadeStatus[playerid][slot]=0;
    return CallLocalFunction("OnFunctionOfEasyScreenFade","dd",slot,playerid);}
TextDrawShowForPlayer(playerid,textdrawid);
return EasyScreenFadeStatus[playerid][slot]++;}
stock SetEasyScreenFade(slot,playerid,Text:textdrawid,colour,bool:mode=false,timer){
TextDrawHideForPlayer(playerid,textdrawid);
EasyScreenFadeStatus[playerid][slot]=0;
KillTimer(DeadlEasyScreenFade[playerid][slot]);
DeadlEasyScreenFade[playerid][slot]=SetTimerEx("EasyScreenFadeUpdate",timer,true,"dddxb",slot,playerid,_:textdrawid,colour,mode);}
stock KillEasyScreenFade(slot,playerid,Text:textdrawid){
TextDrawHideForPlayer(playerid,textdrawid);
EasyScreenFadeStatus[playerid][slot]=0;
KillTimer(DeadlEasyScreenFade[playerid][slot]);}

What is this shit?? Ni el compilador lo podrб leer.
Reply


Messages In This Thread
Easy Screen Fade By OTACON - by OTACON - 23.01.2014, 15:08
Respuesta: Easy Screen Fade By OTACON - by Zume - 23.01.2014, 16:35
Respuesta: Easy Screen Fade By OTACON - by CrossOv3r - 23.01.2014, 16:49
Respuesta: Easy Screen Fade By OTACON - by PolloLoko - 21.06.2014, 15:25
Respuesta: Easy Screen Fade By OTACON - by Swedky - 21.06.2014, 15:31
Respuesta: Easy Screen Fade By OTACON - by deryan - 21.06.2014, 16:49
Respuesta: Easy Screen Fade By OTACON - by OTACON - 21.06.2014, 21:05
Respuesta: Easy Screen Fade By OTACON - by PolloLoko - 23.06.2014, 05:39
Respuesta: Easy Screen Fade By OTACON - by OTACON - 23.06.2014, 05:45

Forum Jump:


Users browsing this thread: 4 Guest(s)