mirror of https://github.com/AxioDL/metaforce.git
Windows fixes
This commit is contained in:
parent
0dc6729144
commit
3a24b35df7
|
@ -8,7 +8,7 @@ if(MSVC)
|
|||
|
||||
# Shaddup MSVC
|
||||
add_definitions(-DUNICODE=1 -D_UNICODE=1 -D__SSE__=1 -D_CRT_SECURE_NO_WARNINGS=1 -DD_SCL_SECURE_NO_WARNINGS=1
|
||||
/IGNORE:4221 /wd4800 /wd4005 /wd4311 /wd4267 /wd4244 /wd4200 /wd4305 ${VS_DEFINES})
|
||||
/IGNORE:4221 /wd4800 /wd4005 /wd4311 /wd4267 /wd4244 /wd4200 /wd4305 /wd4067 /wd4146 ${VS_DEFINES})
|
||||
|
||||
# Link-time Code Generation for Release builds
|
||||
set(CMAKE_C_FLAGS_RELEASE "/DNDEBUG /O2 /Oy /GL /Gy /MD")
|
||||
|
|
|
@ -889,7 +889,7 @@ bool TXTR::CookPC(const hecl::ProjectPath& inPath, const hecl::ProjectPath& outP
|
|||
switch (colorType)
|
||||
{
|
||||
case PNG_COLOR_TYPE_GRAY:
|
||||
for (int i=0 ; i<width ; ++i)
|
||||
for (unsigned i=0 ; i<width ; ++i)
|
||||
{
|
||||
size_t outbase = (r*width+i)*4;
|
||||
bufOut[outbase] = rowBuf[i];
|
||||
|
|
|
@ -240,8 +240,8 @@ void SplashScreen::resized(const boo::SWindowRect& root, const boo::SWindowRect&
|
|||
boo::SWindowRect badgeRect = centerRect;
|
||||
badgeRect.location[0] += LINE_WIDTH * pf;
|
||||
badgeRect.location[1] += BADGE_MARGIN * pf;
|
||||
badgeRect.size[0] = BADGE_WIDTH;
|
||||
badgeRect.size[1] = BADGE_HEIGHT;
|
||||
badgeRect.size[0] = BADGE_WIDTH * pf;
|
||||
badgeRect.size[1] = BADGE_HEIGHT * pf;
|
||||
|
||||
boo::SWindowRect textRect = centerRect;
|
||||
textRect.location[0] += TEXT_MARGIN * pf;
|
||||
|
|
|
@ -15,10 +15,9 @@ else()
|
|||
set(CMAKE_FIND_APPBUNDLE FIRST)
|
||||
find_program(INKSCAPE_BIN inkscape)
|
||||
endif()
|
||||
if(INKSCAPE_BIN STREQUAL "INKSCAPE_BIN-NOTFOUND")
|
||||
message(STATUS "Inkscape not found; downloading icons")
|
||||
file(DOWNLOAD "https://www.dropbox.com/s/wnj17dwgcsky0o9/icons.bin"
|
||||
${CMAKE_CURRENT_BINARY_DIR}/icons.bin SHOW_PROGRESS)
|
||||
if(NOT INKSCAPE_BIN)
|
||||
add_custom_command(OUTPUT icons.bin COMMAND ${CMAKE_COMMAND} ARGS -P
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/IconDownload.cmake)
|
||||
else()
|
||||
message(STATUS "Inkscape found; will render icons locally")
|
||||
add_custom_command(OUTPUT icons.bin COMMAND $<TARGET_FILE:packicons>
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
message(STATUS "Inkscape not found; downloading icons to '${CMAKE_CURRENT_BINARY_DIR}/icons.bin'")
|
||||
file(DOWNLOAD "https://www.dropbox.com/s/wnj17dwgcsky0o9/icons.bin"
|
||||
${CMAKE_CURRENT_BINARY_DIR}/icons.bin SHOW_PROGRESS)
|
|
@ -32,7 +32,7 @@ private:
|
|||
u32 x34_size;
|
||||
u8* x38_moStart;
|
||||
u8* x3c_vertexStart;
|
||||
u32 x40_surfaceStart;
|
||||
u8* x40_surfaceStart;
|
||||
std::unique_ptr<u8[]> x44_buf;
|
||||
public:
|
||||
CMapArea(CInputStream&, u32);
|
||||
|
|
|
@ -32,9 +32,9 @@ public:
|
|||
void SetLayerActive(int areaIdx, int layerIdx, bool active)
|
||||
{
|
||||
if (active)
|
||||
x0_areaLayers[areaIdx].m_layerBits |= 1 << layerIdx;
|
||||
x0_areaLayers[areaIdx].m_layerBits |= uint64_t(1) << layerIdx;
|
||||
else
|
||||
x0_areaLayers[areaIdx].m_layerBits &= ~(1 << layerIdx);
|
||||
x0_areaLayers[areaIdx].m_layerBits &= ~(uint64_t(1) << layerIdx);
|
||||
}
|
||||
|
||||
void InitializeWorldLayers(const std::vector<CWorldLayers::Area>& layers);
|
||||
|
|
|
@ -59,7 +59,7 @@ CCharLayoutInfo::CCharLayoutInfo(CInputStream& in)
|
|||
x8_segIdList(in)
|
||||
{
|
||||
atUint32 mapCount = in.readUint32Big();
|
||||
for (int i=0 ; i<mapCount ; ++i)
|
||||
for (atUint32 i=0 ; i<mapCount ; ++i)
|
||||
{
|
||||
std::string key = in.readString();
|
||||
x18_segIdMap.emplace(key, in);
|
||||
|
|
|
@ -29,7 +29,7 @@ void CFBStreamedAnimReaderTotals::Initialize(const CFBStreamedCompression& sourc
|
|||
|
||||
if (source.m_pc)
|
||||
{
|
||||
for (int b=0 ; b<boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<boneChanCount ; ++b)
|
||||
{
|
||||
xc_segIds2[b] = *reinterpret_cast<const u32*>(chans);
|
||||
chans += 8;
|
||||
|
@ -59,7 +59,7 @@ void CFBStreamedAnimReaderTotals::Initialize(const CFBStreamedCompression& sourc
|
|||
}
|
||||
else
|
||||
{
|
||||
for (int b=0 ; b<boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<boneChanCount ; ++b)
|
||||
{
|
||||
xc_segIds2[b] = *reinterpret_cast<const u32*>(chans);
|
||||
chans += 6;
|
||||
|
@ -111,7 +111,7 @@ void CFBStreamedAnimReaderTotals::IncrementInto(CBitLevelLoader& loader,
|
|||
|
||||
if (source.m_pc)
|
||||
{
|
||||
for (int b=0 ; b<boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<boneChanCount ; ++b)
|
||||
{
|
||||
chans += 8;
|
||||
|
||||
|
@ -138,7 +138,7 @@ void CFBStreamedAnimReaderTotals::IncrementInto(CBitLevelLoader& loader,
|
|||
}
|
||||
else
|
||||
{
|
||||
for (int b=0 ; b<boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<boneChanCount ; ++b)
|
||||
{
|
||||
chans += 6;
|
||||
|
||||
|
@ -167,7 +167,7 @@ void CFBStreamedAnimReaderTotals::IncrementInto(CBitLevelLoader& loader,
|
|||
|
||||
void CFBStreamedAnimReaderTotals::CalculateDown()
|
||||
{
|
||||
for (int b=0 ; b<x24_boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<x24_boneChanCount ; ++b)
|
||||
{
|
||||
const s32* cumulativesIn = &x4_cumulativeInts32[8*b];
|
||||
float* compOut = &x10_computedFloats32[8*b];
|
||||
|
@ -213,7 +213,7 @@ void CFBStreamedPairOfTotals::SetTime(CBitLevelLoader& loader, const CCharAnimTi
|
|||
int prior = -1;
|
||||
int next = -1;
|
||||
int cur = 0;
|
||||
for (int b=0 ; b<timeBitmap[0] ; ++b)
|
||||
for (unsigned b=0 ; b<timeBitmap[0] ; ++b)
|
||||
{
|
||||
int word = b / 32;
|
||||
int bit = b % 32;
|
||||
|
@ -243,7 +243,7 @@ void CFBStreamedPairOfTotals::SetTime(CBitLevelLoader& loader, const CCharAnimTi
|
|||
curTime += interval;
|
||||
}
|
||||
|
||||
if (prior != -1 && prior < Prior().x1c_curKey)
|
||||
if (prior != -1 && u32(prior) < Prior().x1c_curKey)
|
||||
{
|
||||
Prior().Initialize(*x0_source);
|
||||
Next().Initialize(*x0_source);
|
||||
|
@ -251,7 +251,7 @@ void CFBStreamedPairOfTotals::SetTime(CBitLevelLoader& loader, const CCharAnimTi
|
|||
}
|
||||
|
||||
if (next != -1)
|
||||
while (next > Next().x1c_curKey)
|
||||
while (u32(next) > Next().x1c_curKey)
|
||||
DoIncrement(loader);
|
||||
|
||||
if (!Prior().IsCalculated())
|
||||
|
|
|
@ -41,7 +41,7 @@ const u8* CFBStreamedCompression::GetBitstreamPointer() const
|
|||
|
||||
if (m_pc)
|
||||
{
|
||||
for (int b=0 ; b<boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<boneChanCount ; ++b)
|
||||
{
|
||||
chans += 20;
|
||||
|
||||
|
@ -53,7 +53,7 @@ const u8* CFBStreamedCompression::GetBitstreamPointer() const
|
|||
}
|
||||
else
|
||||
{
|
||||
for (int b=0 ; b<boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<boneChanCount ; ++b)
|
||||
{
|
||||
chans += 15;
|
||||
|
||||
|
@ -102,7 +102,7 @@ u8* CFBStreamedCompression::ReadBoneChannelDescriptors(u8* out, CInputStream& in
|
|||
|
||||
if (m_pc)
|
||||
{
|
||||
for (int b=0 ; b<boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<boneChanCount ; ++b)
|
||||
{
|
||||
*reinterpret_cast<u32*>(out) = in.readUint32Big();
|
||||
out += 4;
|
||||
|
@ -132,7 +132,7 @@ u8* CFBStreamedCompression::ReadBoneChannelDescriptors(u8* out, CInputStream& in
|
|||
}
|
||||
else
|
||||
{
|
||||
for (int b=0 ; b<boneChanCount ; ++b)
|
||||
for (unsigned b=0 ; b<boneChanCount ; ++b)
|
||||
{
|
||||
*reinterpret_cast<u32*>(out) = in.readUint32Big();
|
||||
out += 4;
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#include "CGunWeapon.hpp"
|
||||
#include "GameGlobalObjects.hpp"
|
||||
#include "CSimplePool.hpp"
|
||||
#include "Particle/CGenDescription.hpp"
|
||||
|
||||
namespace urde
|
||||
{
|
||||
|
@ -42,7 +43,7 @@ s32 GetWeaponIndex(EWeaponType type)
|
|||
|
||||
CGunWeapon::CGunWeapon(ResId ancsId, EWeaponType type, TUniqueId uid, EMaterialTypes mType, const zeus::CVector3f& vec)
|
||||
: x4_(vec),
|
||||
x104_gunCharacter(g_SimplePool->GetObj({ancsId, FOURCC('ANCS')})),
|
||||
x104_gunCharacter(g_SimplePool->GetObj(SObjectTag{FOURCC('ANCS'), ancsId})),
|
||||
x13c_armCharacter(g_SimplePool->GetObj(skSuitArmNames[0])),
|
||||
x1c0_weaponType(type),
|
||||
x1c4_uid(uid),
|
||||
|
|
|
@ -21,7 +21,7 @@ enum class EGunAnimType
|
|||
|
||||
class CActorLights;
|
||||
class CGunController;
|
||||
class CModelFlags;
|
||||
struct CModelFlags;
|
||||
class CStateManager;
|
||||
class CGunWeapon
|
||||
{
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#include "CPowerBeam.hpp"
|
||||
#include "Particle/CGenDescription.hpp"
|
||||
|
||||
namespace urde
|
||||
{
|
||||
|
|
2
amuse
2
amuse
|
@ -1 +1 @@
|
|||
Subproject commit eb948dfd63236cceaf4055c032fa7f88c8fa4955
|
||||
Subproject commit 9cf96ad6f94ffa6594a78358d39b195909f0b27c
|
2
hecl
2
hecl
|
@ -1 +1 @@
|
|||
Subproject commit 389c6a2e3d7aaffc132c7d027af8eb17873433ed
|
||||
Subproject commit f610566b0b851cbe91ff72bae7390ac0609b130f
|
2
nod
2
nod
|
@ -1 +1 @@
|
|||
Subproject commit bcfe1a5d33c6a191489b37ff6144a78b36099a03
|
||||
Subproject commit 512a8a122d51c3bea20d0e2572c0d2dd6d6f1dce
|
2
specter
2
specter
|
@ -1 +1 @@
|
|||
Subproject commit ac2ebd5499cfcdb6183c7fa26618555575f9b9c6
|
||||
Subproject commit 78471d73feb3761887a019cf02b83df1c7423832
|
Loading…
Reference in New Issue