Windows Fixes

This commit is contained in:
Phillip Stephens 2017-01-29 22:08:44 -08:00
parent e276bd3be9
commit 1960103f6c
5 changed files with 9 additions and 9 deletions

View File

@ -18,7 +18,7 @@ struct DeafBabe : BigDNA
DECL_DNA
Value<atUint32> material;
bool unknown() const { return material & 1; }
void setUnknown(bool v) { material &= ~1; material |= v; }
void setUnknown(bool v) { material &= ~1; material |= int(v); }
bool surfaceStone() const { return (material >> 1) & 1; }
void setSurfaceStone(bool v) { material &= ~(1ull << 1); material |= (v << 1); }
bool surfaceMetal() const { return (material >> 2) & 1; }

View File

@ -18,7 +18,7 @@ struct DeafBabe : BigDNA
DECL_DNA
Value<atUint64> material;
bool unknown() const { return material & 1; }
void setUnknown(bool v) { material &= ~1; material |= v; }
void setUnknown(bool v) { material &= ~1; material |= atUint64(v); }
bool surfaceStone() const { return (material >> 1ull) & 1; }
void setSurfaceStone(bool v) { material &= ~(1ull << 1ull); material |= (atUint64(v) << 1ull); }
bool surfaceMetal() const { return (material >> 2) & 1; }

View File

@ -76,22 +76,22 @@ CModelShaders::GetShaderExtensionsHLSL(boo::IGraphicsDataFactory::Platform plat)
hecl::Runtime::ShaderCacheExtensions ext(plat);
/* Normal lit shading */
ext.registerExtensionSlot({LightingMetal, "LightingFunc"}, {MainPostMetal, "MainPostFunc"},
ext.registerExtensionSlot({LightingHLSL, "LightingFunc"}, {MainPostHLSL, "MainPostFunc"},
0, nullptr, 0, nullptr, hecl::Backend::BlendFactor::Original,
hecl::Backend::BlendFactor::Original);
/* Thermal Visor shading */
ext.registerExtensionSlot({}, {ThermalPostMetal, "ThermalPostFunc"}, 0, nullptr,
ext.registerExtensionSlot({}, {ThermalPostHLSL, "ThermalPostFunc"}, 0, nullptr,
1, ThermalTextures, hecl::Backend::BlendFactor::One,
hecl::Backend::BlendFactor::One);
/* Forced alpha shading */
ext.registerExtensionSlot({LightingMetal, "LightingFunc"}, {MainPostMetal, "MainPostFunc"},
ext.registerExtensionSlot({LightingHLSL, "LightingFunc"}, {MainPostHLSL, "MainPostFunc"},
0, nullptr, 0, nullptr, hecl::Backend::BlendFactor::SrcAlpha,
hecl::Backend::BlendFactor::InvSrcAlpha);
/* Forced additive shading */
ext.registerExtensionSlot({LightingMetal, "LightingFunc"}, {MainPostMetal, "MainPostFunc"},
ext.registerExtensionSlot({LightingHLSL, "LightingFunc"}, {MainPostHLSL, "MainPostFunc"},
0, nullptr, 0, nullptr, hecl::Backend::BlendFactor::One,
hecl::Backend::BlendFactor::One);

View File

@ -9,7 +9,7 @@ namespace urde
CScriptMemoryRelay::CScriptMemoryRelay(TUniqueId uid, const std::string& name, const CEntityInfo& info, bool b1, bool b2, bool b3)
: CEntity(uid, info, true, name),
x34_24_(b1),
x34_25_skipSendNone(b2),
x34_25_skipSendActive(b2),
x34_26_ignoreMessages(b3)
{
}
@ -32,7 +32,7 @@ void CScriptMemoryRelay::AcceptScriptMsg(EScriptObjectMessage msg, TUniqueId obj
else if (msg == EScriptObjectMessage::Activate)
{
stateMgr.GetRelayTracker()->AddRelay(xc_editorId);
if (!x34_25_skipSendNone)
if (!x34_25_skipSendActive)
SendScriptMsgs(EScriptObjectState::Active, stateMgr, EScriptObjectMessage::None);
return;

View File

@ -12,7 +12,7 @@ class CScriptMemoryRelay : public CEntity
struct
{
bool x34_24_;
bool x34_25_skipSendNone;
bool x34_25_skipSendActive;
bool x34_26_ignoreMessages;
};
u8 dummy = 0;