Mercurial > mm7
comparison LOD.cpp @ 1165:29a8defbad9e
temporary _CRT_SECURE_NO_WARNINGS to remove some warnings
removed double LOBYTE, LOWORD etd macro definitions
swprintf called with string size parameter
ErrD3D with too many params fix
1 or 2 other minor fixes
author | Grumpy7 |
---|---|
date | Tue, 04 Jun 2013 03:21:21 +0200 |
parents | 5d5c78088274 |
children | 5450af4f57ef |
comparison
equal
deleted
inserted
replaced
1164:6b911d7e09a5 | 1165:29a8defbad9e |
---|---|
1 #ifdef _MSC_VER | |
2 #define _CRT_SECURE_NO_WARNINGS | |
3 #endif | |
4 | |
1 #include "LOD.h" | 5 #include "LOD.h" |
2 #include "Render.h" | 6 #include "Render.h" |
3 #include "Allocator.h" | 7 #include "Allocator.h" |
4 #include "PaletteManager.h" | 8 #include "PaletteManager.h" |
5 #include "Viewport.h" | 9 #include "Viewport.h" |
2013 | 2017 |
2014 | 2018 |
2015 if (bLinearSearch) | 2019 if (bLinearSearch) |
2016 { | 2020 { |
2017 for (uint i = 0; i < uNumSubDirs; ++i) | 2021 for (uint i = 0; i < uNumSubDirs; ++i) |
2018 if (!strcmpi(pContainer_Name, pSubIndices[i].pFilename)) | 2022 if (!_stricmp(pContainer_Name, pSubIndices[i].pFilename)) |
2019 { | 2023 { |
2020 v4 = pSubIndices[i].uOfsetFromSubindicesStart; | 2024 v4 = pSubIndices[i].uOfsetFromSubindicesStart; |
2021 fseek(pFile, uOffsetToSubIndex + v4, SEEK_SET); | 2025 fseek(pFile, uOffsetToSubIndex + v4, SEEK_SET); |
2022 return pFile; | 2026 return pFile; |
2023 } | 2027 } |
2638 memset(pHardwareTextures, 0, 1000 * sizeof(IDirect3DTexture2 *)); | 2642 memset(pHardwareTextures, 0, 1000 * sizeof(IDirect3DTexture2 *)); |
2639 | 2643 |
2640 ptr_011BB4 = new char[1000]; | 2644 ptr_011BB4 = new char[1000]; |
2641 memset(ptr_011BB4, 0, 1000); | 2645 memset(ptr_011BB4, 0, 1000); |
2642 } | 2646 } |
2643 if (strnicmp(pContainer, "wtrdr", 5))//*v4 != 'w' || v4[1] != 't' || v4[2] != 'r' || v4[3] != 'd' || v4[4] != 'r' ) | 2647 if (_strnicmp(pContainer, "wtrdr", 5))//*v4 != 'w' || v4[1] != 't' || v4[2] != 'r' || v4[3] != 'd' || v4[4] != 'r' ) |
2644 { | 2648 { |
2645 if (strnicmp(pContainer, "WtrTyl", 6))//if ( *v4 != 'W' || v4[1] != 't' || v4[2] != 'r' || v4[3] != 'T' || v4[4] != 'y' || v4[5] != 'l' ) | 2649 if (_strnicmp(pContainer, "WtrTyl", 6))//if ( *v4 != 'W' || v4[1] != 't' || v4[2] != 'r' || v4[3] != 'T' || v4[4] != 'y' || v4[5] != 'l' ) |
2646 { | 2650 { |
2647 v14 = uNumLoadedFiles; | 2651 v14 = uNumLoadedFiles; |
2648 } | 2652 } |
2649 else | 2653 else |
2650 { | 2654 { |
2897 //v3 = this; | 2901 //v3 = this; |
2898 //v4 = 0; | 2902 //v4 = 0; |
2899 areWeLoadingTexture = 1; | 2903 areWeLoadingTexture = 1; |
2900 | 2904 |
2901 for (uint i = 0; i < uNumLoadedFiles; ++i) | 2905 for (uint i = 0; i < uNumLoadedFiles; ++i) |
2902 if (!strcmpi(pContainer, pTextures[i].pName)) | 2906 if (!_stricmp(pContainer, pTextures[i].pName)) |
2903 return i; | 2907 return i; |
2904 | 2908 |
2905 // if (!uNumLoadedFiles) | 2909 // if (!uNumLoadedFiles) |
2906 // { | 2910 // { |
2907 //LABEL_5: | 2911 //LABEL_5: |