Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Client/core/CConsole.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ bool CConsole::IsEnabled()

void CConsole::SetEnabled(bool bEnabled)
{
// Hide it if neccessary
// Hide it if necessary
if (!bEnabled && m_pWindow->IsVisible())
{
SetVisible(false);
Expand Down
2 changes: 1 addition & 1 deletion Client/core/CGUI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -745,7 +745,7 @@ bool CLocalGUI::ProcessMessage(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lPara
return true;
case WM_IME_KEYDOWN:
{
// Handle space/return seperately in this case
// Handle space/return separately in this case
if (wParam == VK_SPACE)
pGUI->ProcessCharacter(MapVirtualKey(wParam, MAPVK_VK_TO_CHAR));

Expand Down
2 changes: 1 addition & 1 deletion Client/core/CScreenShot.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ static bool ms_bBeforeGUI = false;

static SString ms_strScreenDirectoryPath;

// Last save time, seperated per given type
// Last save time, separated per given type
// (normal screenshot or camera weapon initiated)
static long long ms_lLastSaveTime[2] = {0, 0};

Expand Down
2 changes: 1 addition & 1 deletion Client/core/CTrayIcon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ bool CTrayIcon::CreateTrayIcon()
return false;
}

// The handle to the core.dll is neccessary here,
// The handle to the core.dll is necessary here,
// because Windows will search for the ICON in the executable and not in the DLL
// Note: Changing the size will not show a higher quality icon in the balloon
auto hIcon = LoadImage(g_hModule, MAKEINTRESOURCE(IDI_ICON1), IMAGE_ICON, LR_DEFAULTSIZE, LR_DEFAULTSIZE, LR_SHARED | LR_LOADTRANSPARENT);
Expand Down
2 changes: 1 addition & 1 deletion Client/core/DXHook/CDirect3DHookManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* PROJECT: Multi Theft Auto
* LICENSE: See LICENSE in the top level directory
* FILE: Client/core/DXHook/CDirect3DHookManager.cpp
* PURPOSE: Direct3D version independant hook manager
* PURPOSE: Direct3D version independent hook manager
*
* Multi Theft Auto is available from https://multitheftauto.com/
*
Expand Down
10 changes: 5 additions & 5 deletions Client/core/DXHook/CProxyDirect3D9.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1194,7 +1194,7 @@ namespace
//
// Hook CCore::OnPreCreateDevice
//
// Modify paramters
// Modify parameters
//
////////////////////////////////////////////////
void CCore::OnPreCreateDevice(IDirect3D9* pDirect3D, UINT Adapter, D3DDEVTYPE DeviceType, HWND hFocusWindow, DWORD& BehaviorFlags,
Expand Down Expand Up @@ -1224,7 +1224,7 @@ void CCore::OnPreCreateDevice(IDirect3D9* pDirect3D, UINT Adapter, D3DDEVTYPE De
BehaviorFlagsOrig = BehaviorFlags;
presentationParametersOrig = *pPresentationParameters;

WriteDebugEvent(" Original paramters:");
WriteDebugEvent(" Original parameters:");
WriteDebugEvent(ToString(Adapter, DeviceType, hFocusWindow, BehaviorFlags, *pPresentationParameters));

// Make sure DirectX Get...() calls will work
Expand All @@ -1235,7 +1235,7 @@ void CCore::OnPreCreateDevice(IDirect3D9* pDirect3D, UINT Adapter, D3DDEVTYPE De

GetVideoModeManager()->PreCreateDevice(pPresentationParameters);

WriteDebugEvent(" Modified paramters:");
WriteDebugEvent(" Modified parameters:");
WriteDebugEvent(ToString(Adapter, DeviceType, hFocusWindow, BehaviorFlags, *pPresentationParameters));
}

Expand Down Expand Up @@ -1309,7 +1309,7 @@ HRESULT CCore::OnPostCreateDevice(HRESULT hResult, IDirect3D9* pDirect3D, UINT A
BehaviorFlagsOrig = BehaviorFlags;
presentationParametersOrig = *pPresentationParameters;

WriteDebugEvent(" Original paramters:");
WriteDebugEvent(" Original parameters:");
WriteDebugEvent(ToString(Adapter, DeviceType, hFocusWindow, BehaviorFlags, *pPresentationParameters));

// Make sure DirectX Get...() calls will work
Expand All @@ -1320,7 +1320,7 @@ HRESULT CCore::OnPostCreateDevice(HRESULT hResult, IDirect3D9* pDirect3D, UINT A

GetVideoModeManager()->PreCreateDevice(pPresentationParameters);

WriteDebugEvent(" Modified paramters:");
WriteDebugEvent(" Modified parameters:");
WriteDebugEvent(ToString(Adapter, DeviceType, hFocusWindow, BehaviorFlags, *pPresentationParameters));

hResult = CreateDeviceInsist(2, 1000, pDirect3D, Adapter, DeviceType, hFocusWindow, BehaviorFlags, pPresentationParameters, ppReturnedDeviceInterface);
Expand Down
4 changes: 2 additions & 2 deletions Client/core/DXHook/CProxyDirect3DEffect.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ HRESULT CProxyDirect3DEffect::CloneEffect(LPDIRECT3DDEVICE9 pDevice, LPD3DXEFFEC
//
// MyD3DXCreateEffectFromFile
//
// Wrap result of orignal function
// Wrap result of original function
//
/////////////////////////////////////////////////////////////
HRESULT WINAPI MyD3DXCreateEffectFromFile(LPDIRECT3DDEVICE9 pDevice, LPCSTR pSrcFile, CONST D3DXMACRO* pDefines, LPD3DXINCLUDE pInclude, DWORD Flags,
Expand All @@ -192,7 +192,7 @@ HRESULT WINAPI MyD3DXCreateEffectFromFile(LPDIRECT3DDEVICE9 pDevice, LPCSTR pSrc
//
// D3DXCreateEffect
//
// Wrap result of orignal function
// Wrap result of original function
//
/////////////////////////////////////////////////////////////
HRESULT WINAPI MyD3DXCreateEffect(LPDIRECT3DDEVICE9 pDevice, LPCVOID pSrcData, UINT SrcDataLen, CONST D3DXMACRO* pDefines, LPD3DXINCLUDE pInclude, DWORD Flags,
Expand Down
2 changes: 1 addition & 1 deletion Client/core/DXHook/CProxyDirectInput8.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ CProxyDirectInput8::CProxyDirectInput8(IDirectInput8* pDevice)
{
WriteDebugEvent(SString("CProxyDirectInput8::CProxyDirectInput8 %08x", this));

// Initalize our local variable.
// Initialize our local variable.
m_pDevice = pDevice;
}

Expand Down
12 changes: 6 additions & 6 deletions Client/core/Graphics/CMaterialLine3DBatcher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ void CMaterialLine3DBatcher::Flush()
std::vector<uint> indexList;
indexList.resize(uiNumLines);
uint* pIndices = &indexList[0];
uint uiNumIndicies = 0;
uint uiNumIndices = 0;

// Calculate distances
for (uint i = 0; i < uiNumLines; i++)
Expand All @@ -149,12 +149,12 @@ void CMaterialLine3DBatcher::Flush()
continue;
}
// Add the index for this line to the draw list
pIndices[uiNumIndicies++] = i;
pIndices[uiNumIndices++] = i;
}

if (uiNumIndicies > 0)
if (uiNumIndices > 0)
{
indexList.resize(uiNumIndicies);
indexList.resize(uiNumIndices);

// Sort index list by distance
ms_pLines = &m_LineList[0];
Expand All @@ -164,12 +164,12 @@ void CMaterialLine3DBatcher::Flush()

// Draw index list, batching by material
uint uiBatchFirstIndex = 0;
for (uint i = 0; i < uiNumIndicies; i++)
for (uint i = 0; i < uiNumIndices; i++)
{
const SMaterialLine3DItem& item = ms_pLines[pIndices[i]];

// Flush batch if this is the last index, or the next one uses a different material
if ((i == uiNumIndicies - 1) || item.pMaterial != ms_pLines[pIndices[i + 1]].pMaterial)
if ((i == uiNumIndices - 1) || item.pMaterial != ms_pLines[pIndices[i + 1]].pMaterial)
{
uint* pBatchIndices = &pIndices[uiBatchFirstIndex];
uint uiNumBatchLines = i - uiBatchFirstIndex + 1;
Expand Down
2 changes: 1 addition & 1 deletion Client/core/Graphics/CRenderItem.EffectParameters.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1076,7 +1076,7 @@ bool CEffectParameters::TryParseSpecialParameter(D3DXHANDLE hParameter, const D3
//
// CEffectParameters::IsSecondaryRenderTarget
//
// Return true if paramter is flagged for use as a secondary render target texture
// Return true if parameter is flagged for use as a secondary render target texture
//
////////////////////////////////////////////////////////////////
bool CEffectParameters::IsSecondaryRenderTarget(D3DXHANDLE hParameter, const D3DXPARAMETER_DESC& ParameterDesc)
Expand Down
4 changes: 2 additions & 2 deletions Client/game_sa/CAnimBlendStaticAssociationSA.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class CAnimBlendStaticAssociationSAInterface
short sAnimGroup;
short sFlags;
int* pAnimBlendNodesSequenceArray;
CAnimBlendHierarchySAInterface* pAnimHeirarchy;
CAnimBlendHierarchySAInterface* pAnimHierarchy;
};

class CAnimBlendStaticAssociationSA : public CAnimBlendStaticAssociation
Expand All @@ -47,7 +47,7 @@ class CAnimBlendStaticAssociationSA : public CAnimBlendStaticAssociation
short GetAnimID() { return m_pInterface->sAnimID; }
short GetAnimGroup() { return m_pInterface->sAnimGroup; }
short GetFlags() { return m_pInterface->sFlags; }
CAnimBlendHierarchySAInterface* GetAnimHierachyInterface() { return m_pInterface->pAnimHeirarchy; }
CAnimBlendHierarchySAInterface* GetAnimHierarchyInterface() { return m_pInterface->pAnimHierarchy; }
CAnimBlendStaticAssociationSAInterface* GetInterface() { return m_pInterface; }

protected:
Expand Down
2 changes: 1 addition & 1 deletion Client/game_sa/CCameraSA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ void CCameraSA::RestoreWithJumpCut()
}

/**
* \todo Find out what the last two paramters are
* \todo Find out what the last two parameters are
*/
void CCameraSA::TakeControl(CEntity* entity, eCamMode CamMode, int CamSwitchStyle)
{
Expand Down
4 changes: 2 additions & 2 deletions Client/game_sa/CHudSA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ CHudSA::CHudSA()
MemPut<DWORD>(0x53E488 + 2, (DWORD)&m_fSniperCrosshairScale);
MemPut<DWORD>(0x53E4BF + 2, (DWORD)&m_fSniperCrosshairScale);

// Initalize default data
// Initialize default data
componentProperties.hpBar = MapGet(defaultComponentProperties, HUD_HEALTH);
componentProperties.breathBar = MapGet(defaultComponentProperties, HUD_BREATH);
componentProperties.armorBar = MapGet(defaultComponentProperties, HUD_ARMOUR);
Expand Down Expand Up @@ -169,7 +169,7 @@ void CHudSA::SetComponentVisible(eHudComponent component, bool bVisible)
SHudComponent* pComponent = MapFind(m_HudComponentMap, component);
if (pComponent)
{
// Save original bytes if requred
// Save original bytes if required
if (pComponent->bSaveOriginalBytes)
{
pComponent->origData = *(DWORD*)pComponent->uiDataAddr;
Expand Down
2 changes: 1 addition & 1 deletion Client/game_sa/CPedSA.h
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class CPedFlags
unsigned int bIsStanding : 1; // is ped standing on something
unsigned int bWasStanding : 1; // was ped standing on something
unsigned int bIsLooking : 1; // is ped looking at something or in a direction
unsigned int bIsRestoringLook : 1; // is ped restoring head postion from a look
unsigned int bIsRestoringLook : 1; // is ped restoring head position from a look
unsigned int bIsAimingGun : 1; // is ped aiming gun
unsigned int bIsRestoringGun : 1; // is ped moving gun back to default posn
unsigned int bCanPointGunAtTarget : 1; // can ped point gun at target
Expand Down
4 changes: 2 additions & 2 deletions Client/game_sa/CPlayerInfoSA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ CWanted* CPlayerInfoSA::GetWanted()

/**
* Gets the amount of money the player has
* @return DWORD containing the ammount of money the player has
* @return DWORD containing the amount of money the player has
*/
long CPlayerInfoSA::GetPlayerMoney()
{
Expand All @@ -32,7 +32,7 @@ long CPlayerInfoSA::GetPlayerMoney()

/**
* Sets the amount of money the player has
* @param dwMoney DWORD containing the ammount of money you wish the player to have
* @param dwMoney DWORD containing the amount of money you wish the player to have
*/
void CPlayerInfoSA::SetPlayerMoney(long lMoney, bool bInstant)
{
Expand Down
2 changes: 1 addition & 1 deletion Client/game_sa/CPlayerPedSA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ bool IsBlendAssocGroupValid(int iGroup)
CAnimBlendStaticAssociationSAInterface* pAssociation = pBlendAssocGroup->pAssociationsArray + iUseAnimId;
if (pAssociation == NULL)
return false;
if (pAssociation->pAnimHeirarchy == NULL)
if (pAssociation->pAnimHierarchy == NULL)
return false;
}
return true;
Expand Down
8 changes: 4 additions & 4 deletions Client/game_sa/CStatsSA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,31 +30,31 @@ float CStatsSA::GetStatValue(unsigned short usIndex)
return fReturn;
}

void CStatsSA::ModifyStat(unsigned short usIndex, float fAmmount)
void CStatsSA::ModifyStat(unsigned short usIndex, float fAmount)
{
DWORD dwFunc = FUNC_ModifyStat;
DWORD dwStatIndex = usIndex;

// clang-format off
__asm
{
push fAmmount
push fAmount
push dwStatIndex
call dwFunc
add esp, 8
}
// clang-format on
}

void CStatsSA::SetStatValue(unsigned short usIndex, float fAmmount)
void CStatsSA::SetStatValue(unsigned short usIndex, float fAmount)
{
DWORD dwFunc = FUNC_SetStatValue;
DWORD dwStatIndex = usIndex;

// clang-format off
__asm
{
push fAmmount
push fAmount
push dwStatIndex
call dwFunc
add esp, 8
Expand Down
4 changes: 2 additions & 2 deletions Client/game_sa/CStatsSA.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ class CStatsSA : public CStats
{
public:
float GetStatValue(unsigned short usIndex);
void ModifyStat(unsigned short usIndex, float fAmmount);
void SetStatValue(unsigned short usIndex, float fAmmount);
void ModifyStat(unsigned short usIndex, float fAmount);
void SetStatValue(unsigned short usIndex, float fAmount);

unsigned short GetSkillStatIndex(eWeaponType type);
};
2 changes: 1 addition & 1 deletion Client/game_sa/CVehicleSA.h
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ struct CVehicleFlags
unsigned char bLowVehicle : 1; // Need this for sporty type cars to use low getting-in/out anims
unsigned char bComedyControls : 1; // Will make the car hard to control (hopefully in a funny way)
unsigned char bWarnedPeds : 1; // Has scan and warn peds of danger been processed?
unsigned char bCraneMessageDone : 1; // A crane message has been printed for this car allready
unsigned char bCraneMessageDone : 1; // A crane message has been printed for this car already
// unsigned char bExtendedRange: 1; // This vehicle needs to be a bit further away to get deleted
unsigned char bTakeLessDamage : 1; // This vehicle is stronger (takes about 1/4 of damage)

Expand Down
2 changes: 1 addition & 1 deletion Client/game_sa/TaskSA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ CTaskSA::~CTaskSA()
dwTasksAlive--;
}

// alocate memory for the task (ammount nSize)
// allocate memory for the task (amount nSize)
void CTaskSA::CreateTaskInterface(size_t nSize)
{
// Safety margin. I see GTA allocate more than we do for some tasks. We could create
Expand Down
2 changes: 1 addition & 1 deletion Client/loader-proxy/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,7 @@ BOOL WINAPI MyGetVersionExA(LPOSVERSIONINFOA versionInfo)
// Execute the original function with the given parameter.
BOOL result = Win32GetVersionExA(versionInfo);

// Restore the function pointer we've overriden to get here.
// Restore the function pointer we've overridden to get here.
SetImportProcAddress("kernel32.dll", "GetVersionExA", FunctionPtrToFarProc(Win32GetVersionExA));

// Run our startup code.
Expand Down
2 changes: 1 addition & 1 deletion Client/loader/MainFunctions.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -898,7 +898,7 @@ void ConfigureWerDumpPath()
// Commands are often stored in the registry by the installer and client.
//
// "L0" is opened before the launch sequence and is closed if MTA shutsdown with no error
// "L1" is opened before the launch sequence and is closed if GTA is succesfully started
// "L1" is opened before the launch sequence and is closed if GTA is successfully started
// "CR1" is a counter which is incremented if GTA was not started and MTA shutsdown with an error
//
// "L2" is opened before the launch sequence and is closed if the GTA loading screen is shown
Expand Down
2 changes: 1 addition & 1 deletion Client/mods/deathmatch/ClientCommands.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -717,7 +717,7 @@ void COMMAND_DumpPlayers(const char* szCmdLine)

// End of the dump. Close it
fclose(pFile);
g_pCore->GetConsole()->Print("dumpplayers: Dumping successfull");
g_pCore->GetConsole()->Print("dumpplayers: Dumping successful");
}
else
g_pCore->GetConsole()->Print("dumpplayers: Unable to create file");
Expand Down
10 changes: 5 additions & 5 deletions Client/mods/deathmatch/logic/CClientGame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -679,7 +679,7 @@ bool CClientGame::StartGame(const char* szNick, const char* szPassword, eServerT
NetBitStreamInterface* pBitStream = g_pNet->AllocateNetBitStream();
if (pBitStream)
{
// Hash the password if neccessary
// Hash the password if necessary
MD5 Password;
memset(Password.data, 0, sizeof(MD5));
if (szPassword)
Expand Down Expand Up @@ -1680,15 +1680,15 @@ void CClientGame::SetMimic(unsigned int uiMimicCount)
if (uiMimicCount > MAX_MIMICS)
return;

// Create neccessary players
// Create necessary players
while (m_Mimics.size() < uiMimicCount)
{
CClientPlayer* pPlayer = new CClientPlayer(m_pManager, static_cast<ElementID>(MAX_NET_PLAYERS_REAL + (int)m_Mimics.size()));
pPlayer->SetNick("Mimic");
m_Mimics.push_back(pPlayer);
}

// Destroy neccessary players
// Destroy necessary players
while (m_Mimics.size() > uiMimicCount)
{
CClientPlayer* pPlayer = m_Mimics.back();
Expand Down Expand Up @@ -4019,7 +4019,7 @@ bool CClientGame::AssocGroupCopyAnimationHandler(CAnimBlendAssociationSAInterfac
}

auto pOriginalAnimStaticAssoc = pAnimationManager->GetAnimStaticAssociation(iGroupID, animID);
auto pOriginalAnimHierarchyInterface = pOriginalAnimStaticAssoc->GetAnimHierachyInterface();
auto pOriginalAnimHierarchyInterface = pOriginalAnimStaticAssoc->GetAnimHierarchyInterface();
auto pAnimAssociation = pAnimationManager->GetAnimBlendAssociation(pAnimAssocInterface);

CClientPed* pClientPed = GetClientPedByClump(*pClump);
Expand All @@ -4036,7 +4036,7 @@ bool CClientGame::AssocGroupCopyAnimationHandler(CAnimBlendAssociationSAInterfac
(iGroupID >= eAnimGroup::ANIM_GROUP_PLAYER && iGroupID <= eAnimGroup::ANIM_GROUP_PLAYERJETPACK) || iGroupID >= eAnimGroup::ANIM_GROUP_MAN)
{
auto pDuckAnimStaticAssoc = pAnimationManager->GetAnimStaticAssociation(eAnimGroup::ANIM_GROUP_DEFAULT, eAnimID::ANIM_ID_WEAPON_CROUCH);
pAnimHierarchy = pAnimationManager->GetCustomAnimBlendHierarchy(pDuckAnimStaticAssoc->GetAnimHierachyInterface());
pAnimHierarchy = pAnimationManager->GetCustomAnimBlendHierarchy(pDuckAnimStaticAssoc->GetAnimHierarchyInterface());
isCustomAnimationToPlay = true;
}
}
Expand Down
2 changes: 1 addition & 1 deletion Client/mods/deathmatch/logic/CClientPad.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -746,7 +746,7 @@ void CClientPad::ProcessControl(short& usControlValue, unsigned int uiIndex)
//
// usControlValue is the updated input value we get from the player
// m_sScriptedStates contains our script value
// m_bScriptedStatesNextFrameOverride if the player input should be forcefully overriden for the next frame
// m_bScriptedStatesNextFrameOverride if the player input should be forcefully overridden for the next frame
//
//
// old behavior or (override == false)
Expand Down
Loading
Loading