mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-28 15:02:01 +00:00
- Remove some GCC warnings.
SVN r1157 (trunk)
This commit is contained in:
parent
a876ba55bd
commit
f40d52c22a
2 changed files with 8 additions and 6 deletions
|
@ -2173,6 +2173,7 @@ static void PowerupColor (FScanner &sc, APowerupGiver *defaults, Baggage &bag)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
sc.ScriptError("\"%s\" requires an actor of type \"Powerup\"\n", sc.String);
|
sc.ScriptError("\"%s\" requires an actor of type \"Powerup\"\n", sc.String);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sc.CheckNumber())
|
if (sc.CheckNumber())
|
||||||
|
@ -2231,6 +2232,8 @@ static void PowerupDuration (FScanner &sc, APowerupGiver *defaults, Baggage &bag
|
||||||
{
|
{
|
||||||
int *pEffectTics;
|
int *pEffectTics;
|
||||||
|
|
||||||
|
sc.MustGetNumber();
|
||||||
|
|
||||||
if (bag.Info->Class->IsDescendantOf(RUNTIME_CLASS(APowerup)))
|
if (bag.Info->Class->IsDescendantOf(RUNTIME_CLASS(APowerup)))
|
||||||
{
|
{
|
||||||
pEffectTics = &((APowerup*)defaults)->EffectTics;
|
pEffectTics = &((APowerup*)defaults)->EffectTics;
|
||||||
|
@ -2242,10 +2245,9 @@ static void PowerupDuration (FScanner &sc, APowerupGiver *defaults, Baggage &bag
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
sc.ScriptError("\"%s\" requires an actor of type \"Powerup\"\n", sc.String);
|
sc.ScriptError("\"%s\" requires an actor of type \"Powerup\"\n", sc.String);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
*pEffectTics = (sc.Number >= 0) ? sc.Number : -sc.Number * TICRATE;
|
||||||
sc.MustGetNumber();
|
|
||||||
*pEffectTics = sc.Number>=0? sc.Number : -sc.Number*TICRATE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
|
|
|
@ -492,7 +492,7 @@ int ParseStates(FScanner &sc, FActorInfo * actor, AActor * defaults, Baggage &ba
|
||||||
FState * laststate = NULL;
|
FState * laststate = NULL;
|
||||||
intptr_t lastlabel = -1;
|
intptr_t lastlabel = -1;
|
||||||
int minrequiredstate = -1;
|
int minrequiredstate = -1;
|
||||||
int spriteindex;
|
int spriteindex = 0;
|
||||||
char lastsprite[5]="";
|
char lastsprite[5]="";
|
||||||
|
|
||||||
sc.MustGetStringName ("{");
|
sc.MustGetStringName ("{");
|
||||||
|
|
Loading…
Reference in a new issue