Fix build warnings
This commit is contained in:
1 parent
37895da9b2
commit
18dbb110cc
3 files changed
+16
-12
No files matched your search
@@ -104,7 +104,6 @@
|
|||||||
<IntDir>obj\$(Configuration).$(Platform)\</IntDir>
|
<IntDir>obj\$(Configuration).$(Platform)\</IntDir>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugWin|x64'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DebugWin|x64'">
|
||||||
<LinkIncremental>true</LinkIncremental>
|
|
||||||
<OutDir>bin\$(Configuration).$(Platform)\</OutDir>
|
<OutDir>bin\$(Configuration).$(Platform)\</OutDir>
|
||||||
<IncludePath>$(MSBuildProjectDirectory)\x64\lib\glib-2.0\include;$(MSBuildProjectDirectory)\x64\include\gstreamer-1.0;$(MSBuildProjectDirectory)\x64\include\glib-2.0;$(MSBuildProjectDirectory)\x64\include;$(IncludePath)</IncludePath>
|
<IncludePath>$(MSBuildProjectDirectory)\x64\lib\glib-2.0\include;$(MSBuildProjectDirectory)\x64\include\gstreamer-1.0;$(MSBuildProjectDirectory)\x64\include\glib-2.0;$(MSBuildProjectDirectory)\x64\include;$(IncludePath)</IncludePath>
|
||||||
<LibraryPath>$(MSBuildProjectDirectory)\x64\lib;$(LibraryPath)</LibraryPath>
|
<LibraryPath>$(MSBuildProjectDirectory)\x64\lib;$(LibraryPath)</LibraryPath>
|
||||||
|
|||||||
+10
-4
@@ -15,6 +15,9 @@
|
|||||||
// along with Vocaluxe. If not, see <http://www.gnu.org/licenses/>.
|
// along with Vocaluxe. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
//Uncomment to make the engine hit every note
|
||||||
|
//#define DEBUG_HIT
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using Vocaluxe.SongQueue;
|
using Vocaluxe.SongQueue;
|
||||||
@@ -208,8 +211,6 @@ namespace Vocaluxe.Base
|
|||||||
|
|
||||||
public static void UpdatePoints(float time)
|
public static void UpdatePoints(float time)
|
||||||
{
|
{
|
||||||
const bool DEBUG_HIT = false;
|
|
||||||
|
|
||||||
CSong song = _SongQueue.GetSong();
|
CSong song = _SongQueue.GetSong();
|
||||||
|
|
||||||
if (song == null)
|
if (song == null)
|
||||||
@@ -270,7 +271,11 @@ namespace Vocaluxe.Base
|
|||||||
if (line == lines.Length - 1 && beat == lines[line].LastNoteBeat)
|
if (line == lines.Length - 1 && beat == lines[line].LastNoteBeat)
|
||||||
Players[p].SongFinished = true;
|
Players[p].SongFinished = true;
|
||||||
|
|
||||||
if (notes[note].PointsForBeat > 0 && (CSound.RecordToneValid(p) || DEBUG_HIT))
|
if (notes[note].PointsForBeat > 0 && (CSound.RecordToneValid(p)
|
||||||
|
#if DEBUG_HIT
|
||||||
|
|| true
|
||||||
|
#endif
|
||||||
|
))
|
||||||
{
|
{
|
||||||
int tone = notes[note].Tone;
|
int tone = notes[note].Tone;
|
||||||
int tonePlayer = CSound.RecordGetTone(p);
|
int tonePlayer = CSound.RecordGetTone(p);
|
||||||
@@ -281,8 +286,9 @@ namespace Vocaluxe.Base
|
|||||||
while (tonePlayer - tone < -6)
|
while (tonePlayer - tone < -6)
|
||||||
tonePlayer += 12;
|
tonePlayer += 12;
|
||||||
|
|
||||||
if (DEBUG_HIT)
|
#if DEBUG_HIT
|
||||||
tonePlayer = tone;
|
tonePlayer = tone;
|
||||||
|
#endif
|
||||||
|
|
||||||
Players[p].NoteDiff = Math.Abs(tone - tonePlayer);
|
Players[p].NoteDiff = Math.Abs(tone - tonePlayer);
|
||||||
bool hit = Players[p].NoteDiff <= (2 - (int)CProfiles.GetDifficulty(Players[p].ProfileID));
|
bool hit = Players[p].NoteDiff <= (2 - (int)CProfiles.GetDifficulty(Players[p].ProfileID));
|
||||||
|
|||||||
@@ -15,6 +15,9 @@
|
|||||||
// along with Vocaluxe. If not, see <http://www.gnu.org/licenses/>.
|
// along with Vocaluxe. If not, see <http://www.gnu.org/licenses/>.
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
//Uncomment to make the font write the glyphs to file
|
||||||
|
//#define FONT_DEBUG_OUTPUT
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Drawing;
|
using System.Drawing;
|
||||||
using System.Drawing.Drawing2D;
|
using System.Drawing.Drawing2D;
|
||||||
@@ -119,19 +122,15 @@ namespace Vocaluxe.Base.Fonts
|
|||||||
_DrawBounding.Y *= _Texture.Width / _DrawBounding.Width;
|
_DrawBounding.Y *= _Texture.Width / _DrawBounding.Width;
|
||||||
_DrawBounding.Width = _Texture.Width;
|
_DrawBounding.Width = _Texture.Width;
|
||||||
_DrawBounding.Height = _Texture.Height;*/
|
_DrawBounding.Height = _Texture.Height;*/
|
||||||
#pragma warning disable 162
|
#if FONT_DEBUG_OUTPUT
|
||||||
// ReSharper disable HeuristicUnreachableCode
|
if (Char.IsLetterOrDigit(chr))
|
||||||
// ReSharper disable ConditionIsAlwaysTrueOrFalse
|
|
||||||
if (false && Char.IsLetterOrDigit(chr))
|
|
||||||
{
|
{
|
||||||
if (outline > 0)
|
if (outline > 0)
|
||||||
bmpCropped.Save("font_" + chr + "o" + CFonts.Style + "2.png", ImageFormat.Png);
|
bmpCropped.Save("font_" + chr + "o" + CFonts.Style + "2.png", ImageFormat.Png);
|
||||||
else
|
else
|
||||||
bmpCropped.Save("font_" + chr + CFonts.Style + "2.png", ImageFormat.Png);
|
bmpCropped.Save("font_" + chr + CFonts.Style + "2.png", ImageFormat.Png);
|
||||||
}
|
}
|
||||||
// ReSharper restore ConditionIsAlwaysTrueOrFalse
|
#endif
|
||||||
// ReSharper restore HeuristicUnreachableCode
|
|
||||||
#pragma warning restore 162
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user