Advertisement
ykos

Untitled

Jan 12th, 2021
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.01 KB | None | 0 0
  1. new bool: PlayerBlind[MAX_PLAYERS];
  2. new Text: TD_FullBlackDisplay;
  3.  
  4. // OnPlayerConnect
  5. PlayerBlind[playerid] = false;
  6.  
  7. // OnGameModeInit
  8.     TD_FullBlackDisplay = TextDrawCreate(-2.000000, -7.000000, "box");
  9.     TextDrawLetterSize(TD_FullBlackDisplay, 0.000000, 53.935569);
  10.     TextDrawTextSize(TD_FullBlackDisplay, 638.000000, 0.000000);
  11.     TextDrawAlignment(TD_FullBlackDisplay, 1);
  12.     TextDrawColor(TD_FullBlackDisplay, -1);
  13.     TextDrawUseBox(TD_FullBlackDisplay, 1);
  14.     TextDrawBoxColor(TD_FullBlackDisplay, 255);
  15.     TextDrawSetShadow(TD_FullBlackDisplay, 0);
  16.     TextDrawSetOutline(TD_FullBlackDisplay, 0);
  17.     TextDrawBackgroundColor(TD_FullBlackDisplay, 255);
  18.     TextDrawFont(TD_FullBlackDisplay, 1);
  19.     TextDrawSetProportional(TD_FullBlackDisplay, 1);
  20.     TextDrawSetShadow(TD_FullBlackDisplay, 0);
  21.  
  22.  
  23. CMD:blind(playerid)
  24. {
  25.     PlayerBlind[playerid] = !PlayerBlind[playerid];
  26.     if(PlayerBlind[playerid]) TextDrawShowForPlayer(playerid, TD_FullBlackDisplay);
  27.     else TextDrawHideForPlayer(playerid, TD_FullBlackDisplay); 
  28.     return 1;
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement