mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-26 14:01:45 +00:00
Revert "- fixed some uses of postincre,ment/decrements on narrow types."
This reverts commit668f8f2cf6
. Revert "- added a proper error message when '--' or '++' gets used on 8 or 16 bit values." This reverts commita94f5dd1b3
. None of this was necessary - the triggered assert was bogus and had to be removed.
This commit is contained in:
parent
6ebe30ce44
commit
97b8c0ccfb
5 changed files with 10 additions and 18 deletions
|
@ -239,13 +239,8 @@ void VkRenderBuffers::CreateShadowmap()
|
|||
|
||||
ImageBuilder builder;
|
||||
builder.setSize(gl_shadowmap_quality, 1024);
|
||||
builder.setFormat(SceneNormalFormat);
|
||||
builder.setFormat(VK_FORMAT_R32_SFLOAT);
|
||||
builder.setUsage(VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT | VK_IMAGE_USAGE_SAMPLED_BIT);
|
||||
if (!builder.isFormatSupported(fb->device, VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT | VK_FORMAT_FEATURE_SAMPLED_IMAGE_BIT))
|
||||
{
|
||||
SceneNormalFormat = VK_FORMAT_R8G8B8A8_UNORM;
|
||||
builder.setFormat(SceneNormalFormat);
|
||||
}
|
||||
Shadowmap.Image = builder.create(fb->device);
|
||||
Shadowmap.Image->SetDebugName("VkRenderBuffers.Shadowmap");
|
||||
|
||||
|
|
|
@ -2145,9 +2145,9 @@ FxExpression *FxPreIncrDecr::Resolve(FCompileContext &ctx)
|
|||
|
||||
ValueType = Base->ValueType;
|
||||
|
||||
if (!Base->IsNumeric() || Base->ValueType->Size != 4)
|
||||
if (!Base->IsNumeric())
|
||||
{
|
||||
ScriptPosition.Message(MSG_ERROR, "Numeric 32 bit type expected");
|
||||
ScriptPosition.Message(MSG_ERROR, "Numeric type expected");
|
||||
delete this;
|
||||
return nullptr;
|
||||
}
|
||||
|
@ -2170,7 +2170,6 @@ FxExpression *FxPreIncrDecr::Resolve(FCompileContext &ctx)
|
|||
ExpEmit FxPreIncrDecr::Emit(VMFunctionBuilder *build)
|
||||
{
|
||||
assert(Token == TK_Incr || Token == TK_Decr);
|
||||
assert(ValueType == Base->ValueType && IsNumeric());
|
||||
|
||||
int zero = build->GetConstantInt(0);
|
||||
int regtype = ValueType->GetRegType();
|
||||
|
@ -2232,9 +2231,9 @@ FxExpression *FxPostIncrDecr::Resolve(FCompileContext &ctx)
|
|||
|
||||
ValueType = Base->ValueType;
|
||||
|
||||
if (!Base->IsNumeric() || ValueType->Size != 4)
|
||||
if (!Base->IsNumeric())
|
||||
{
|
||||
ScriptPosition.Message(MSG_ERROR, "Numeric 32 bit type expected");
|
||||
ScriptPosition.Message(MSG_ERROR, "Numeric type expected");
|
||||
delete this;
|
||||
return nullptr;
|
||||
}
|
||||
|
@ -2257,7 +2256,6 @@ FxExpression *FxPostIncrDecr::Resolve(FCompileContext &ctx)
|
|||
ExpEmit FxPostIncrDecr::Emit(VMFunctionBuilder *build)
|
||||
{
|
||||
assert(Token == TK_Incr || Token == TK_Decr);
|
||||
assert(ValueType == Base->ValueType && IsNumeric());
|
||||
|
||||
int zero = build->GetConstantInt(0);
|
||||
int regtype = ValueType->GetRegType();
|
||||
|
|
|
@ -318,8 +318,8 @@ public:
|
|||
// This avoids anomalies with such things as Boom ice and conveyors.
|
||||
DVector2 Vel = { 0,0 };
|
||||
|
||||
int turnticks = 0;
|
||||
bool centering = false;
|
||||
uint8_t turnticks = 0;
|
||||
|
||||
|
||||
bool attackdown = false;
|
||||
|
@ -344,7 +344,7 @@ public:
|
|||
|
||||
int cheats = 0; // bit flags
|
||||
int timefreezer = 0; // Player has an active time freezer
|
||||
int refire = 0; // refired shots are less accurate
|
||||
short refire = 0; // refired shots are less accurate
|
||||
short inconsistant = 0;
|
||||
bool waiting = 0;
|
||||
int killcount = 0, itemcount = 0, secretcount = 0; // for intermission
|
||||
|
|
|
@ -218,8 +218,7 @@ class FireDemon : Actor
|
|||
// Normal movement
|
||||
if (!fdstrafecount)
|
||||
{
|
||||
movecount = movecount - 1;
|
||||
if (movecount < 0 || !MonsterMove ())
|
||||
if (--movecount<0 || !MonsterMove ())
|
||||
{
|
||||
NewChaseDir ();
|
||||
}
|
||||
|
|
|
@ -2652,7 +2652,7 @@ struct PlayerInfo native play // self is what internally is known as player_t
|
|||
native double bob;
|
||||
native vector2 vel;
|
||||
native bool centering;
|
||||
native int turnticks;
|
||||
native uint8 turnticks;
|
||||
native bool attackdown;
|
||||
native bool usedown;
|
||||
native uint oldbuttons;
|
||||
|
@ -2670,7 +2670,7 @@ struct PlayerInfo native play // self is what internally is known as player_t
|
|||
native PSprite psprites;
|
||||
native int cheats;
|
||||
native int timefreezer;
|
||||
native int refire;
|
||||
native int16 refire;
|
||||
native int16 inconsistent;
|
||||
native bool waiting;
|
||||
native int killcount;
|
||||
|
|
Loading…
Reference in a new issue