chore: cleanup

This commit is contained in:
str1k3r committed 2026-10-19 19:37:19 -04:00
1 parent f83c0298ef
commit 69d6a51ad5
10 files changed
+24 -28

No files matched your search

+7 -5
View File
@@ -1362,6 +1362,7 @@
</PropertyGroup>
<PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|Xbox 360'">
<ConfigurationType>StaticLibrary</ConfigurationType>
<WholeProgramOptimization>true</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Release|Xbox 360'">
<ConfigurationType>StaticLibrary</ConfigurationType>
@@ -1515,18 +1516,19 @@
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Xbox 360'">
<ClCompile>
<AdditionalIncludeDirectories>../Headers/Xbox;../Headers;$(ProjectDir);</AdditionalIncludeDirectories>
<PreprocessorDefinitions>_XBOX;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<PreprocessorDefinitions>_XBOX;_LIB;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<ForcedIncludeFiles>$(ProjectDir)\stdafx.h;</ForcedIncludeFiles>
<Optimization>Full</Optimization>
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
<Optimization>Disabled</Optimization>
<FavorSizeOrSpeed>Neither</FavorSizeOrSpeed>
<WholeProgramOptimization>false</WholeProgramOptimization>
</ClCompile>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Xbox 360'">
<ClCompile>
<AdditionalIncludeDirectories>../Headers/Xbox;../Headers;$(ProjectDir);</AdditionalIncludeDirectories>
<PreprocessorDefinitions>_XBOX;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<PreprocessorDefinitions>_XBOX;_LIB;NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
<ForcedIncludeFiles>$(ProjectDir)\stdafx.h;</ForcedIncludeFiles>
+1 -1
View File
@@ -83,7 +83,7 @@ void CInput::Initialise(int iInputStateC, unsigned char ucMapC, unsigned char uc
m_iEffectiveRange = m_iMovementRangeMax - m_iDeadzone;
m_fEffectiveRange = (float)m_iEffectiveRange;
m_iHalfRange = m_iEffectiveRange * 0.75;
m_iHalfRange = static_cast<int>(m_iEffectiveRange * 0.75);
for (int i = 0; i < MAX_JOYPADS; i++)
{
+1 -1
View File
@@ -54,7 +54,7 @@ public:
BYTE *m_pucRightTriggerAxisMap;
unsigned char m_ucMappingValue;
unsigned char m_ucInputStateIndex;
int m_ucInputStateIndex;
CellPadData *m_pInputStates;
};
+6 -6
View File
@@ -530,22 +530,22 @@ bool CInput::ButtonDown(int iPad, unsigned char ucAction)
float CInput::GetJoypadStick_Menu_LX(unsigned char ucPad)
{
return m_Joypads[ucPad].m_iNormalizedLeftThumbX;
return static_cast<float>(m_Joypads[ucPad].m_iNormalizedLeftThumbX);
}
float CInput::GetJoypadStick_Menu_LY(unsigned char ucPad)
{
return m_Joypads[ucPad].m_iNormalizedLeftThumbY;
return static_cast<float>(m_Joypads[ucPad].m_iNormalizedLeftThumbY);
}
float CInput::GetJoypadStick_Menu_RX(unsigned char ucPad)
{
return m_Joypads[ucPad].m_iNormalizedRightThumbX;
return static_cast<float>(m_Joypads[ucPad].m_iNormalizedRightThumbX);
}
float CInput::GetJoypadStick_Menu_RY(unsigned char ucPad)
{
return m_Joypads[ucPad].m_iNormalizedRightThumbY;
return static_cast<float>(m_Joypads[ucPad].m_iNormalizedRightThumbY);
}
unsigned char CInput::GetJoypadLTrigger_Menu(unsigned char ucPad)
@@ -631,7 +631,7 @@ void CInput::SetKeyRepeatRate(float fRepeatDelaySecs, float fRepeatRateSecs)
void CInput::SetDebugSequence(const char *chSequenceA, int (*Func)(LPVOID), LPVOID lpParam)
{
int iLen = strlen(chSequenceA);
int iLen = static_cast<int>(strlen(chSequenceA));
m_sDebugSequenceName = (char *)operator new[](iLen);
strcpy(m_sDebugSequenceName, chSequenceA);
@@ -885,7 +885,7 @@ void CInput::InitTime(void)
LARGE_INTEGER qwTicksPerSec;
QueryPerformanceFrequency(&qwTicksPerSec);
m_fTickToSeconds = 1.0 / (float)(int)qwTicksPerSec.LowPart;
m_fTickToSeconds = static_cast<float>(1.0 / qwTicksPerSec.LowPart);
for (int i = 0; i < MAX_JOYPADS; i++)
{
m_LastActivityTime[i].QuadPart = 0;
+1 -1
View File
@@ -73,7 +73,7 @@ public:
BYTE *m_pucRightTriggerAxisMap;
unsigned char m_ucMappingValue;
unsigned char m_ucInputStateIndex;
int m_ucInputStateIndex;
SDL_Gamepad *m_pGamepad;
};
+4 -3
View File
@@ -4,11 +4,12 @@
CKeyboard::CKeyboard()
{
bActive = false;
pwchResult = L"";
}
void CKeyboard::Tick(void)
{
if (bActive == true && KeyboardOverlap.InternalLow != ERROR_IO_PENDING)
if (bActive && KeyboardOverlap.InternalLow != ERROR_IO_PENDING)
{
if(Func != NULL) Func(lpParam, KeyboardOverlap.dwExtendedError == 0);
bActive = false;
@@ -17,7 +18,7 @@ void CKeyboard::Tick(void)
C_4JInput::EKeyboardResult CKeyboard::RequestKeyboard(LPCWSTR uiTitle, LPCWSTR uiText, LPCWSTR uiDesc, DWORD dwPad, WCHAR *pwchResult, UINT uiMaxChars, int (*Func)(LPVOID, const bool), LPVOID lpParam, C_4JInput::EKeyboardMode eMode)
{
if (bActive == true)
if (bActive)
return C_4JInput::EKeyboard_Cancelled;
this->iPad = (int)dwPad;
@@ -57,7 +58,7 @@ C_4JInput::EKeyboardResult CKeyboard::RequestKeyboard(LPCWSTR uiTitle, LPCWSTR u
//str1k3r - These 2 only exist cause of iggy
C_4JInput::EKeyboardResult CKeyboard::RequestKeyboard(LPCWSTR uiTitle, LPCWSTR uiText, LPCWSTR uiDesc, DWORD dwPad, UINT uiMaxChars, int(*Func)(LPVOID, const bool), LPVOID lpParam, C_4JInput::EKeyboardMode eMode)
{
;
return RequestKeyboard(uiTitle, uiText, uiDesc, dwPad, pwchResult, uiMaxChars, Func, lpParam, eMode);
}
void CKeyboard::GetText(uint16_t *UTF16String)
+1 -1
View File
@@ -48,7 +48,7 @@ public:
BYTE *m_pucRightTriggerAxisMap;
unsigned char m_ucMappingValue;
unsigned char m_ucInputStateIndex;
int m_ucInputStateIndex;
XINPUT_STATE *m_pInputStates;
};
+1 -3
View File
@@ -24,9 +24,7 @@
#include <stdint.h>
#include <assert.h>
#include "4J_Storage.h"
#endif
#ifndef _XBOX
#else
#include "extraX64.h"
#endif