]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Fix inconsistent indentation in 2 files
authorterencehill <piuntn@gmail.com>
Wed, 16 Dec 2020 15:03:08 +0000 (16:03 +0100)
committerterencehill <piuntn@gmail.com>
Wed, 16 Dec 2020 15:03:08 +0000 (16:03 +0100)
qcsrc/client/hud/panel/physics.qc
qcsrc/common/teams.qh

index 977dc797e2247fba66d4f7784ec6cefe5eca1f94..6a0baed31bc124f644e07985d8a65fc33d32a18b 100644 (file)
@@ -136,7 +136,7 @@ void HUD_Physics()
        int speed_baralign, acceleration_baralign;
        if (autocvar_hud_panel_physics_baralign == 1)
                acceleration_baralign = speed_baralign = 1;
-    else if(autocvar_hud_panel_physics_baralign == 4)
+       else if(autocvar_hud_panel_physics_baralign == 4)
                acceleration_baralign = speed_baralign = 2;
        else if (autocvar_hud_panel_physics_flip)
        {
@@ -204,7 +204,7 @@ void HUD_Physics()
                                // divide by f to make it start from 1
                                f = cos( ((time - top_speed_time) / f) * PI/2 );
                        }
-            else //hide top speed 0, it would be stupid
+                       else // hide top speed 0
                                f = 0;
                }
                if (f > 0)
@@ -217,19 +217,19 @@ void HUD_Physics()
                                vector peak_size = '0 0 0';
                                if (speed_baralign == 0)
                                        peak_offsetX = min(top_speed, max_speed)/max_speed * panel_size.x;
-                else if (speed_baralign == 1)
+                               else if (speed_baralign == 1)
                                        peak_offsetX = (1 - min(top_speed, max_speed)/max_speed) * panel_size.x;
-                else // if (speed_baralign == 2)
-                    peak_offsetX = min(top_speed, max_speed)/max_speed * panel_size.x * 0.5;
+                               else // if (speed_baralign == 2)
+                                       peak_offsetX = min(top_speed, max_speed)/max_speed * panel_size.x * 0.5;
                                peak_size.x = floor(panel_size.x * 0.01 + 1.5);
-                peak_size.y = panel_size.y;
-                if (speed_baralign == 2) // draw two peaks, on both sides
-                {
-                    drawfill(panel_pos + speed_offset + eX * (0.5 * panel_size.x + peak_offsetX - peak_size.x), peak_size, autocvar_hud_progressbar_speed_color, f * autocvar_hud_progressbar_alpha * panel_fg_alpha, DRAWFLAG_NORMAL);
-                    drawfill(panel_pos + speed_offset + eX * (0.5 * panel_size.x - peak_offsetX + peak_size.x), peak_size, autocvar_hud_progressbar_speed_color, f * autocvar_hud_progressbar_alpha * panel_fg_alpha, DRAWFLAG_NORMAL);
-                }
-                else
-                    drawfill(panel_pos + speed_offset + eX * (peak_offsetX - peak_size.x), peak_size, autocvar_hud_progressbar_speed_color, f * autocvar_hud_progressbar_alpha * panel_fg_alpha, DRAWFLAG_NORMAL);
+                               peak_size.y = panel_size.y;
+                               if (speed_baralign == 2) // draw two peaks, on both sides
+                               {
+                                       drawfill(panel_pos + speed_offset + eX * (0.5 * panel_size.x + peak_offsetX - peak_size.x), peak_size, autocvar_hud_progressbar_speed_color, f * autocvar_hud_progressbar_alpha * panel_fg_alpha, DRAWFLAG_NORMAL);
+                                       drawfill(panel_pos + speed_offset + eX * (0.5 * panel_size.x - peak_offsetX + peak_size.x), peak_size, autocvar_hud_progressbar_speed_color, f * autocvar_hud_progressbar_alpha * panel_fg_alpha, DRAWFLAG_NORMAL);
+                               }
+                               else
+                                       drawfill(panel_pos + speed_offset + eX * (peak_offsetX - peak_size.x), peak_size, autocvar_hud_progressbar_speed_color, f * autocvar_hud_progressbar_alpha * panel_fg_alpha, DRAWFLAG_NORMAL);
                        }
 
                        //top speed
index 62bb2db7cdda28a8e6e63da5cf6024e59f570a3e..62c3e7b162b2aa11e27962da6e49b218889cbc91 100644 (file)
@@ -3,19 +3,19 @@
 const int NUM_TEAMS = 4; ///< Number of teams in the game.
 
 #ifdef TEAMNUMBERS_THAT_ARENT_STUPID
-const int NUM_TEAM_1 = 1;  // red
+const int NUM_TEAM_1 = 1; // red
 const int NUM_TEAM_2 = 2; // blue
 const int NUM_TEAM_3 = 3; // yellow
 const int NUM_TEAM_4 = 4; // pink
 const int NUM_SPECTATOR = 5;
 #else
 #ifdef CSQC
-const int NUM_TEAM_1 = 4;  // red
+const int NUM_TEAM_1 = 4; // red
 const int NUM_TEAM_2 = 13; // blue
 const int NUM_TEAM_3 = 12; // yellow
 const int NUM_TEAM_4 = 9; // pink
 #else
-const int NUM_TEAM_1 = 5;  // red
+const int NUM_TEAM_1 = 5; // red
 const int NUM_TEAM_2 = 14; // blue
 const int NUM_TEAM_3 = 13; // yellow
 const int NUM_TEAM_4 = 10; // pink
@@ -83,7 +83,7 @@ vector Team_ColorRGB(int teamid)
                case NUM_TEAM_4: return '1 0.0625 1'; // 0xFF0FFF
        }
 
-    return '0 0 0';
+       return '0 0 0';
 }
 
 string Team_ColorName(int teamid)
@@ -96,7 +96,7 @@ string Team_ColorName(int teamid)
                case NUM_TEAM_4: return NAME_TEAM_4;
        }
 
-    return NAME_NEUTRAL;
+       return NAME_NEUTRAL;
 }
 
 // used for replacement in filenames or such where the name CANNOT be allowed to be translated
@@ -110,7 +110,7 @@ string Static_Team_ColorName(int teamid)
                case NUM_TEAM_4: return STATIC_NAME_TEAM_4;
        }
 
-    return NAME_NEUTRAL;
+       return NAME_NEUTRAL;
 }
 
 float Team_ColorToTeam(string team_color)