- fixed: WIF_STAFF2_KICKBACK did not work anymore because it depended on conditions

that were changed some time ago.
- fixed: The damage inflictor for a rail attack was the shooter, not the puff.
- Fixed: Floor and ceiling huggers may not change their z-velocity when seeking.
- Fixed: UDMF set the secret sector flag before parsing the sector's properties,
  resulting in it always being false.
- Renamed sector's oldspecial variable to secretsector to better reflect its
  only use.
- Fixed: A_BrainSpit stored as the SpawnShot's target the intended BossTarget, 
  not itself contrarily to other projectile spawning functions. 
  A_SpawnFly then used the target for CopyFriendliness, thinking it'll be the 
  BossEye when in fact it wasn't.
- Added Gez's submission for a DEHACKED hack introduced by Boom.
  (using code pointers of the form 'Pointer 0 (x statenumber)'.
- fixed: Attaching 3DMidtex lines by sector tag did not work because lines
  were marked by index in the sector's line list but needed to be marked by
  line index in the global array.
- fixed: On Linux ZDoom was creating a directory called "~.zdoom" for 
  save files because of a missing slash.
- fixed: UDMF was unable to read floating point values in exponential format
  because the C Mode scanner was missing a definition for them.
- fixed: The recent changes for removing pointer aliasing got the end sequence
  info from an incorrect variable. To make this more robust the sequence index
  is now stored as a hexadecimal string to avoid storing binary data in a string.
  Also moved end sequence lookup from f_finale.cpp to the calling code so that
  the proper end sequences can be retrieved for secret exits, too.

SVN r1777 (trunk)
This commit is contained in:
Christoph Oelckers 2009-08-30 10:43:51 +00:00
parent 6e3fdbdfc8
commit ba28749df7
24 changed files with 933 additions and 581 deletions

View file

@ -1,4 +1,35 @@
August 28, 2009 August 29, 2009 (Changes by Graf Zahl)
- fixed: WIF_STAFF2_KICKBACK did not work anymore because it depended on conditions
that were changed some time ago.
- fixed: The damage inflictor for a rail attack was the shooter, not the puff.
- Fixed: Floor and ceiling huggers may not change their z-velocity when seeking.
- Fixed: UDMF set the secret sector flag before parsing the sector's properties,
resulting in it always being false.
- Renamed sector's oldspecial variable to secretsector to better reflect its
only use.
- Fixed: A_BrainSpit stored as the SpawnShot's target the intended BossTarget,
not itself contrarily to other projectile spawning functions.
A_SpawnFly then used the target for CopyFriendliness, thinking it'll be the
BossEye when in fact it wasn't.
- Added Gez's submission for a DEHACKED hack introduced by Boom.
(using code pointers of the form 'Pointer 0 (x statenumber)'.
- fixed: Attaching 3DMidtex lines by sector tag did not work because lines
were marked by index in the sector's line list but needed to be marked by
line index in the global array.
- fixed: On Linux ZDoom was creating a directory called "~.zdoom" for
save files because of a missing slash.
- fixed: UDMF was unable to read floating point values in exponential format
because the C Mode scanner was missing a definition for them.
- fixed: The recent changes for removing pointer aliasing got the end sequence
info from an incorrect variable. To make this more robust the sequence index
is now stored as a hexadecimal string to avoid storing binary data in a string.
Also moved end sequence lookup from f_finale.cpp to the calling code so that
the proper end sequences can be retrieved for secret exits, too.
August 28, 2009 (Changes by Graf Zahl)
- fixed: Switching a weapon did not reset the refire counter.
August 28, 2009
- Fixed: The first lighting plane added to a light stack had the bOverlaps - Fixed: The first lighting plane added to a light stack had the bOverlaps
flag set, causing it to be ignored during rendering. Why this didn't cause flag set, causing it to be ignored during rendering. Why this didn't cause
more trouble, I don't know. more trouble, I don't know.

View file

@ -1429,7 +1429,7 @@ static bool AM_CheckSecret(line_t *line)
{ {
if (line->frontsector != NULL) if (line->frontsector != NULL)
{ {
if (line->frontsector->oldspecial) if (line->frontsector->secretsector)
{ {
if (am_map_secrets!=0 && !(line->frontsector->special&SECRET_MASK)) return true; if (am_map_secrets!=0 && !(line->frontsector->special&SECRET_MASK)) return true;
if (am_map_secrets==2 && !(line->flags & ML_SECRET)) return true; if (am_map_secrets==2 && !(line->flags & ML_SECRET)) return true;
@ -1437,7 +1437,7 @@ static bool AM_CheckSecret(line_t *line)
} }
if (line->backsector != NULL) if (line->backsector != NULL)
{ {
if (line->backsector->oldspecial) if (line->backsector->secretsector)
{ {
if (am_map_secrets!=0 && !(line->backsector->special&SECRET_MASK)) return true; if (am_map_secrets!=0 && !(line->backsector->special&SECRET_MASK)) return true;
if (am_map_secrets==2 && !(line->flags & ML_SECRET)) return true; if (am_map_secrets==2 && !(line->flags & ML_SECRET)) return true;

View file

@ -1373,9 +1373,31 @@ static int PatchPointer (int ptrNum)
{ {
int result; int result;
if (ptrNum >= 0 && ptrNum < 448) { // Hack for some Boom dehacked patches that are of the form Pointer 0 (x statenumber)
char * key;
int indexnum;
key=strchr(Line2, '(');
if (key++) key=strchr(key, ' '); else key=NULL;
if ((ptrNum == 0) && key++)
{
*strchr(key, ')') = '\0';
indexnum = atoi(key);
for (ptrNum = 0; (unsigned int) ptrNum < CodePConv.Size(); ++ptrNum)
{
if (CodePConv[ptrNum] == indexnum) break;
}
DPrintf("Final ptrNum: %i\n", ptrNum);
}
// End of hack.
// 448 Doom states with codepointers + 74 extra MBF states with codepointers = 522 total
// Better to just use the size of the array rather than a hardcoded value.
if (ptrNum >= 0 && (unsigned int) ptrNum < CodePConv.Size())
{
DPrintf ("Pointer %d\n", ptrNum); DPrintf ("Pointer %d\n", ptrNum);
} else { }
else
{
Printf ("Pointer %d out of range.\n", ptrNum); Printf ("Pointer %d out of range.\n", ptrNum);
ptrNum = -1; ptrNum = -1;
} }

View file

@ -191,10 +191,19 @@ void DThinker::SerializeAll(FArchive &arc, bool hubLoad)
statcount--; statcount--;
} }
} }
catch (class CDoomError &) catch (class CDoomError &err)
{ {
bSerialOverride = false; bSerialOverride = false;
DestroyAllThinkers();
// DestroyAllThinkers cannot be called here. It will try to delete the corrupted
// object table left behind by the serializer and crash.
// Trying to continue is not an option here because the garbage collector will
// crash the next time it runs.
// Even making this a fatal error will crash but at least the message can be seen
// before the crash - which is not the case with all other options.
//DestroyAllThinkers();
I_FatalError(err.GetMessage());
throw; throw;
} }
bSerialOverride = false; bSerialOverride = false;

View file

@ -88,7 +88,8 @@ void F_AdvanceSlideshow ();
// F_StartFinale // F_StartFinale
// //
void F_StartFinale (const char *music, int musicorder, int cdtrack, unsigned int cdid, const char *flat, void F_StartFinale (const char *music, int musicorder, int cdtrack, unsigned int cdid, const char *flat,
const char *text, INTBOOL textInLump, INTBOOL finalePic, INTBOOL lookupText, bool ending) const char *text, INTBOOL textInLump, INTBOOL finalePic, INTBOOL lookupText,
bool ending, int endsequence)
{ {
bool loopmusic = ending ? !gameinfo.noloopfinalemusic : true; bool loopmusic = ending ? !gameinfo.noloopfinalemusic : true;
gameaction = ga_nothing; gameaction = ga_nothing;
@ -146,11 +147,12 @@ void F_StartFinale (const char *music, int musicorder, int cdtrack, unsigned int
FinaleEndCount = 70; FinaleEndCount = 70;
FadeDir = -1; FadeDir = -1;
FinaleEnding = ending; FinaleEnding = ending;
FinaleSequence = endsequence;
S_StopAllChannels (); S_StopAllChannels ();
if (ending) if (ending)
{ {
FinaleSequence = level.EndSequence;
if (EndSequences[FinaleSequence].EndType == END_Chess) if (EndSequences[FinaleSequence].EndType == END_Chess)
{ {
TEXTSPEED = 3; // Slow the text to its original rate to match the music. TEXTSPEED = 3; // Slow the text to its original rate to match the music.
@ -244,7 +246,6 @@ void F_Ticker ()
// [RH] Don't automatically advance end-of-game messages // [RH] Don't automatically advance end-of-game messages
if (interrupt) if (interrupt)
{ {
FinaleSequence = level.EndSequence;
if (EndSequences[FinaleSequence].EndType == END_Cast) if (EndSequences[FinaleSequence].EndType == END_Cast)
{ {
F_StartCast (); F_StartCast ();

View file

@ -43,7 +43,8 @@ void F_Drawer ();
void F_StartFinale (const char *music, int musicorder, int cdtrack, unsigned int cdid, const char *flat, void F_StartFinale (const char *music, int musicorder, int cdtrack, unsigned int cdid, const char *flat,
const char *text, INTBOOL textInLump, INTBOOL finalePic, INTBOOL lookupText, bool ending); const char *text, INTBOOL textInLump, INTBOOL finalePic, INTBOOL lookupText,
bool ending, int endsequence = 0);
void F_StartSlideshow (); void F_StartSlideshow ();

View file

@ -141,7 +141,8 @@ static void SpawnFly(AActor *self, const PClass *spawntype, FSoundID sound)
{ {
AActor *newmobj; AActor *newmobj;
AActor *fog; AActor *fog;
AActor *targ; AActor *eye = self->master; // The eye is the spawnshot's master, not the target!
AActor *targ = self->target; // Unlike other projectiles, the target is the intended destination.
int r; int r;
// [GZ] Should be more viable than a countdown... // [GZ] Should be more viable than a countdown...
@ -156,8 +157,6 @@ static void SpawnFly(AActor *self, const PClass *spawntype, FSoundID sound)
return; // still flying return; // still flying
} }
targ = self->target;
if (spawntype != NULL) if (spawntype != NULL)
{ {
fog = Spawn (spawntype, targ->x, targ->y, targ->z, ALLOW_REPLACE); fog = Spawn (spawntype, targ->x, targ->y, targ->z, ALLOW_REPLACE);
@ -174,8 +173,8 @@ static void SpawnFly(AActor *self, const PClass *spawntype, FSoundID sound)
drop = self->GetDropItems(); drop = self->GetDropItems();
// If not, then default back to its master's list // If not, then default back to its master's list
if (drop == NULL && self->master != NULL) if (drop == NULL && eye != NULL)
drop = self->master->GetDropItems(); drop = eye->GetDropItems();
if (drop != NULL) if (drop != NULL)
{ {
@ -192,7 +191,7 @@ static void SpawnFly(AActor *self, const PClass *spawntype, FSoundID sound)
} }
di = drop; di = drop;
n = pr_spawnfly(n); n = pr_spawnfly(n);
while (n > 0) while (n >= 0)
{ {
if (di->Name != NAME_None) if (di->Name != NAME_None)
{ {
@ -235,8 +234,6 @@ static void SpawnFly(AActor *self, const PClass *spawntype, FSoundID sound)
if (newmobj != NULL) if (newmobj != NULL)
{ {
// Make the new monster hate what the boss eye hates // Make the new monster hate what the boss eye hates
AActor *eye = self->target;
if (eye != NULL) if (eye != NULL)
{ {
newmobj->CopyFriendliness (eye, false); newmobj->CopyFriendliness (eye, false);

View file

@ -99,6 +99,8 @@ DEFINE_ACTION_FUNCTION(AActor, A_Tracer)
self->velx = FixedMul (self->Speed, finecosine[exact]); self->velx = FixedMul (self->Speed, finecosine[exact]);
self->vely = FixedMul (self->Speed, finesine[exact]); self->vely = FixedMul (self->Speed, finesine[exact]);
if (!(self->flags3 & (MF3_FLOORHUGGER|MF3_CEILINGHUGGER)))
{
// change slope // change slope
dist = P_AproxDistance (dest->x - self->x, dist = P_AproxDistance (dest->x - self->x,
dest->y - self->y); dest->y - self->y);
@ -122,6 +124,7 @@ DEFINE_ACTION_FUNCTION(AActor, A_Tracer)
else else
self->velz += FRACUNIT/8; self->velz += FRACUNIT/8;
} }
}
DEFINE_ACTION_FUNCTION(AActor, A_SkelWhoosh) DEFINE_ACTION_FUNCTION(AActor, A_SkelWhoosh)

View file

@ -1825,7 +1825,7 @@ FString G_BuildSaveName (const char *prefix, int slot)
#ifdef unix #ifdef unix
if (leader.IsEmpty()) if (leader.IsEmpty())
{ {
leader = "~" GAME_DIR; leader = "~/" GAME_DIR;
} }
#endif #endif
} }

View file

@ -168,8 +168,7 @@ static void SetEndSequence (char *nextmap, int type)
newseq.EndType = type; newseq.EndType = type;
seqnum = (int)EndSequences.Push (newseq); seqnum = (int)EndSequences.Push (newseq);
} }
strcpy (nextmap, "enDSeQ"); mysnprintf(nextmap, sizeof(nextmap), "enDSeQ%04x", (WORD)seqnum);
*((WORD *)(nextmap + 6)) = (WORD)seqnum;
} }
//========================================================================== //==========================================================================
@ -712,7 +711,7 @@ void G_DoCompleted (void)
{ {
if (strncmp (nextlevel, "enDSeQ", 6) == 0) if (strncmp (nextlevel, "enDSeQ", 6) == 0)
{ {
wminfo.next = FString(nextlevel, 8); wminfo.next = nextlevel;
wminfo.LName1 = NULL; wminfo.LName1 = NULL;
} }
else else
@ -1022,7 +1021,7 @@ void G_WorldDone (void)
thiscluster->flags & CLUSTER_EXITTEXTINLUMP, thiscluster->flags & CLUSTER_EXITTEXTINLUMP,
thiscluster->flags & CLUSTER_FINALEPIC, thiscluster->flags & CLUSTER_FINALEPIC,
thiscluster->flags & CLUSTER_LOOKUPEXITTEXT, thiscluster->flags & CLUSTER_LOOKUPEXITTEXT,
true); true, strtol(nextlevel.GetChars()+6, NULL, 16));
} }
else else
{ {
@ -1285,10 +1284,10 @@ void G_InitLevelLocals ()
level.musicorder = info->musicorder; level.musicorder = info->musicorder;
level.LevelName = level.info->LookupLevelName(); level.LevelName = level.info->LookupLevelName();
strncpy (level.nextmap, info->nextmap, 8); strncpy (level.nextmap, info->nextmap, 10);
level.nextmap[8] = 0; level.nextmap[10] = 0;
strncpy (level.secretmap, info->secretmap, 8); strncpy (level.secretmap, info->secretmap, 10);
level.secretmap[8] = 0; level.secretmap[10] = 0;
strncpy (level.skypic1, info->skypic1, 8); strncpy (level.skypic1, info->skypic1, 8);
level.skypic1[8] = 0; level.skypic1[8] = 0;
if (!level.skypic2[0]) if (!level.skypic2[0])

View file

@ -240,12 +240,19 @@ typedef TMap<FName, FOptionalMapinfoDataPtr> FOptData;
struct level_info_t struct level_info_t
{ {
char mapname[9];
int levelnum; int levelnum;
char mapname[9];
char pname[9]; char pname[9];
char nextmap[9]; char nextmap[11]; // The endsequence string is 10 chars so we need more space here
char secretmap[9]; char secretmap[11];
char skypic1[9]; char skypic1[9];
char skypic2[9];
char fadetable[9];
char f1[9];
char bordertexture[9];
char mapbg[9];
int cluster; int cluster;
int partime; int partime;
int sucktime; int sucktime;
@ -253,14 +260,11 @@ struct level_info_t
DWORD flags2; DWORD flags2;
FString Music; FString Music;
FString LevelName; FString LevelName;
char fadetable[9];
SBYTE WallVertLight, WallHorizLight; SBYTE WallVertLight, WallHorizLight;
char f1[9];
int musicorder; int musicorder;
FCompressedMemFile *snapshot; FCompressedMemFile *snapshot;
DWORD snapshotVer; DWORD snapshotVer;
struct acsdefered_t *defered; struct acsdefered_t *defered;
char skypic2[9];
float skyspeed1; float skyspeed1;
float skyspeed2; float skyspeed2;
DWORD fadeto; DWORD fadeto;
@ -287,8 +291,6 @@ struct level_info_t
FString SoundInfo; FString SoundInfo;
FString SndSeq; FString SndSeq;
char bordertexture[9];
char mapbg[9];
float teamdamage; float teamdamage;
@ -355,20 +357,9 @@ struct FLevelLocals
int levelnum; int levelnum;
int lumpnum; int lumpnum;
FString LevelName; FString LevelName;
union char mapname[256]; // the lump name (E1M1, MAP01, etc)
{ char nextmap[11]; // go here when using the regular exit
char mapname[256]; // the server name (base1, etc) char secretmap[11]; // map to go to when used secret exit
// The endsequence is embedded in the name so that it can be
// carried around as a name. The first 6 character ought to
// match the string "enDSeQ".
struct
{
char pad[6];
WORD EndSequence;
};
};
char nextmap[9]; // go here when fraglimit is hit
char secretmap[9]; // map to go to when used secret exit
DWORD flags; DWORD flags;
DWORD flags2; DWORD flags2;

View file

@ -901,6 +901,7 @@ void FMapInfoParser::ParseNextMap(char *mapname)
else else
{ {
strncpy (mapname, sc.String, 8); strncpy (mapname, sc.String, 8);
mapname[8] = 0;
} }
if (useseq) if (useseq)
{ {
@ -915,8 +916,8 @@ void FMapInfoParser::ParseNextMap(char *mapname)
{ {
seqnum = (int)EndSequences.Push (newSeq); seqnum = (int)EndSequences.Push (newSeq);
} }
strcpy (mapname, "enDSeQ"); // mapname can point to nextmap and secretmap which are both 12 characters long
*((WORD *)(mapname + 6)) = (WORD)seqnum; mysnprintf(mapname, 11, "enDSeQ%04x", (WORD)seqnum);
} }
} }
} }

View file

@ -117,6 +117,8 @@ DEFINE_ACTION_FUNCTION(AActor, A_Tracer2)
self->velx = FixedMul (self->Speed, finecosine[exact]); self->velx = FixedMul (self->Speed, finecosine[exact]);
self->vely = FixedMul (self->Speed, finesine[exact]); self->vely = FixedMul (self->Speed, finesine[exact]);
if (!(self->flags3 & (MF3_FLOORHUGGER|MF3_CEILINGHUGGER)))
{
// change slope // change slope
dist = P_AproxDistance (dest->x - self->x, dest->y - self->y); dist = P_AproxDistance (dest->x - self->x, dest->y - self->y);
dist /= self->Speed; dist /= self->Speed;
@ -142,3 +144,4 @@ DEFINE_ACTION_FUNCTION(AActor, A_Tracer2)
self->velz += FRACUNIT/8; self->velz += FRACUNIT/8;
} }
} }
}

View file

@ -170,7 +170,8 @@ void P_Attach3dMidtexLinesToSector(sector_t *sector, int lineid, int tag, bool c
// Only consider two-sided lines with the 3DMIDTEX flag // Only consider two-sided lines with the 3DMIDTEX flag
continue; continue;
} }
found_lines[line>>3] |= 1 << (line&7); int lineno = int(ln-lines);
found_lines[lineno>>3] |= 1 << (lineno&7);
} }
} }
} }

View file

@ -1063,7 +1063,7 @@ void P_DamageMobj (AActor *target, AActor *inflictor, AActor *source, int damage
thrust *= 4; thrust *= 4;
} }
ang >>= ANGLETOFINESHIFT; ang >>= ANGLETOFINESHIFT;
if (source && source->player && (source == inflictor) if (source && source->player && (flags & DMG_INFLICTOR_IS_PUFF)
&& source->player->ReadyWeapon != NULL && && source->player->ReadyWeapon != NULL &&
(source->player->ReadyWeapon->WeaponFlags & WIF_STAFF2_KICKBACK)) (source->player->ReadyWeapon->WeaponFlags & WIF_STAFF2_KICKBACK))
{ {

View file

@ -3567,6 +3567,11 @@ void P_RailAttack (AActor *source, int damage, int offset, int color1, int color
AActor *puffDefaults = puffclass == NULL? NULL : GetDefaultByType (puffclass); AActor *puffDefaults = puffclass == NULL? NULL : GetDefaultByType (puffclass);
FName damagetype = (puffDefaults == NULL || puffDefaults->DamageType == NAME_None) ? FName(NAME_Railgun) : puffDefaults->DamageType; FName damagetype = (puffDefaults == NULL || puffDefaults->DamageType == NAME_None) ? FName(NAME_Railgun) : puffDefaults->DamageType;
// used as damage inflictor
AActor *thepuff = NULL;
if (puffclass != NULL) thepuff = Spawn (puffclass, source->x, source->y, source->z, ALLOW_REPLACE);
for (i = 0; i < RailHits.Size (); i++) for (i = 0; i < RailHits.Size (); i++)
{ {
fixed_t x, y, z; fixed_t x, y, z;
@ -3585,7 +3590,7 @@ void P_RailAttack (AActor *source, int damage, int offset, int color1, int color
P_SpawnBlood (x, y, z, source->angle - ANG180, damage, RailHits[i].HitActor); P_SpawnBlood (x, y, z, source->angle - ANG180, damage, RailHits[i].HitActor);
P_TraceBleed (damage, x, y, z, RailHits[i].HitActor, source->angle, pitch); P_TraceBleed (damage, x, y, z, RailHits[i].HitActor, source->angle, pitch);
} }
P_DamageMobj (RailHits[i].HitActor, source, source, damage, damagetype); P_DamageMobj (RailHits[i].HitActor, thepuff? thepuff:source, source, damage, damagetype, DMG_INFLICTOR_IS_PUFF);
} }
// Spawn a decal or puff at the point where the trace ended. // Spawn a decal or puff at the point where the trace ended.
@ -3597,22 +3602,20 @@ void P_RailAttack (AActor *source, int damage, int offset, int color1, int color
trace.CrossedWater == NULL && trace.CrossedWater == NULL &&
trace.Sector->heightsec == NULL) trace.Sector->heightsec == NULL)
{ {
AActor *thepuff = Spawn (puffclass, trace.X, trace.Y, trace.Z, ALLOW_REPLACE);
if (thepuff != NULL) if (thepuff != NULL)
{ {
thepuff->SetOrigin(trace.X, trace.Y, trace.Z);
P_HitWater (thepuff, trace.Sector); P_HitWater (thepuff, trace.Sector);
thepuff->Destroy ();
} }
} }
if (trace.CrossedWater) if (trace.CrossedWater)
{ {
AActor *thepuff = Spawn (puffclass, 0, 0, 0, ALLOW_REPLACE);
if (thepuff != NULL) if (thepuff != NULL)
{ {
SpawnDeepSplash (source, trace, thepuff, vx, vy, vz, shootz); SpawnDeepSplash (source, trace, thepuff, vx, vy, vz, shootz);
}
}
thepuff->Destroy (); thepuff->Destroy ();
}
}
// Draw the slug's trail. // Draw the slug's trail.
end.X = FIXED2FLOAT(trace.X); end.X = FIXED2FLOAT(trace.X);

View file

@ -1472,6 +1472,9 @@ bool P_SeekerMissile (AActor *actor, angle_t thresh, angle_t turnMax)
angle = actor->angle>>ANGLETOFINESHIFT; angle = actor->angle>>ANGLETOFINESHIFT;
actor->velx = FixedMul (actor->Speed, finecosine[angle]); actor->velx = FixedMul (actor->Speed, finecosine[angle]);
actor->vely = FixedMul (actor->Speed, finesine[angle]); actor->vely = FixedMul (actor->Speed, finesine[angle]);
if (!(actor->flags3 & (MF3_FLOORHUGGER|MF3_CEILINGHUGGER)))
{
if (actor->z + actor->height < target->z || if (actor->z + actor->height < target->z ||
target->z + target->height < actor->z) target->z + target->height < actor->z)
{ // Need to seek vertically { // Need to seek vertically
@ -1483,6 +1486,9 @@ bool P_SeekerMissile (AActor *actor, angle_t thresh, angle_t turnMax)
} }
actor->velz = ((target->z+target->height/2) - (actor->z+actor->height/2)) / dist; actor->velz = ((target->z+target->height/2) - (actor->z+actor->height/2)) / dist;
} }
}
return true; return true;
} }

View file

@ -335,7 +335,7 @@ void P_SerializeWorld (FArchive &arc)
<< sec->Flags << sec->Flags
<< sec->FloorSkyBox << sec->CeilingSkyBox << sec->FloorSkyBox << sec->CeilingSkyBox
<< sec->ZoneNumber << sec->ZoneNumber
<< sec->oldspecial << sec->secretsector
<< sec->interpolations[0] << sec->interpolations[0]
<< sec->interpolations[1] << sec->interpolations[1]
<< sec->interpolations[2] << sec->interpolations[2]

View file

@ -1323,7 +1323,7 @@ void P_LoadSectors (MapData * map)
ss->special = LittleShort(ms->special); ss->special = LittleShort(ms->special);
else // [RH] Translate to new sector special else // [RH] Translate to new sector special
ss->special = P_TranslateSectorSpecial (LittleShort(ms->special)); ss->special = P_TranslateSectorSpecial (LittleShort(ms->special));
ss->oldspecial = !!(ss->special&SECRET_MASK); ss->secretsector = !!(ss->special&SECRET_MASK);
ss->tag = LittleShort(ms->tag); ss->tag = LittleShort(ms->tag);
ss->thinglist = NULL; ss->thinglist = NULL;
ss->touching_thinglist = NULL; // phares 3/14/98 ss->touching_thinglist = NULL; // phares 3/14/98

View file

@ -1013,7 +1013,6 @@ struct UDMFParser
sec->SetYScale(sector_t::floor, FRACUNIT); sec->SetYScale(sector_t::floor, FRACUNIT);
sec->SetXScale(sector_t::ceiling, FRACUNIT); sec->SetXScale(sector_t::ceiling, FRACUNIT);
sec->SetYScale(sector_t::ceiling, FRACUNIT); sec->SetYScale(sector_t::ceiling, FRACUNIT);
sec->oldspecial = !!(sec->special&SECRET_MASK);
sec->thinglist = NULL; sec->thinglist = NULL;
sec->touching_thinglist = NULL; // phares 3/14/98 sec->touching_thinglist = NULL; // phares 3/14/98
sec->seqType = (level.flags & LEVEL_SNDSEQTOTALCTRL)? 0:-1; sec->seqType = (level.flags & LEVEL_SNDSEQTOTALCTRL)? 0:-1;
@ -1177,6 +1176,7 @@ struct UDMFParser
} }
} }
sec->secretsector = !!(sec->special&SECRET_MASK);
sec->floorplane.d = -sec->GetPlaneTexZ(sector_t::floor); sec->floorplane.d = -sec->GetPlaneTexZ(sector_t::floor);
sec->floorplane.c = FRACUNIT; sec->floorplane.c = FRACUNIT;
sec->floorplane.ic = FRACUNIT; sec->floorplane.ic = FRACUNIT;

View file

@ -693,7 +693,7 @@ struct sector_t
FExtraLight *ExtraLights; FExtraLight *ExtraLights;
vertex_t *Triangle[3]; // Three points that can define a plane vertex_t *Triangle[3]; // Three points that can define a plane
short oldspecial; //jff 2/16/98 remembers if sector WAS secret (automap) short secretsector; //jff 2/16/98 remembers if sector WAS secret (automap)
int sectornum; // for comparing sector copies int sectornum; // for comparing sector copies
extsector_t * e; // This stores data that requires construction/destruction. Such data must not be copied by R_FakeFlat. extsector_t * e; // This stores data that requires construction/destruction. Such data must not be copied by R_FakeFlat.

View file

@ -4121,7 +4121,8 @@ yy627:
#line 4122 "src/sc_man_scanner.h" #line 4122 "src/sc_man_scanner.h"
{ {
YYCTYPE yych; YYCTYPE yych;
if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); unsigned int yyaccept = 0;
if((YYLIMIT - YYCURSOR) < 5) YYFILL(5);
yych = *YYCURSOR; yych = *YYCURSOR;
if(yych <= ':') { if(yych <= ':') {
if(yych <= '&') { if(yych <= '&') {
@ -4169,46 +4170,56 @@ yy627:
} }
} }
yy631: yy631:
yyaccept = 0;
yych = *(YYMARKER = ++YYCURSOR); yych = *(YYMARKER = ++YYCURSOR);
if(yych == '*') goto yy677; if(yych == '*') goto yy700;
if(yych == '/') goto yy675; if(yych == '/') goto yy698;
yy632: yy632:
#line 258 "src/sc_man_scanner.re" #line 259 "src/sc_man_scanner.re"
{ goto normal_token; } { goto normal_token; }
#line 4179 "src/sc_man_scanner.h" #line 4181 "src/sc_man_scanner.h"
yy633: yy633:
++YYCURSOR; ++YYCURSOR;
yych = *YYCURSOR; yych = *YYCURSOR;
goto yy674; goto yy697;
yy634: yy634:
#line 246 "src/sc_man_scanner.re" #line 246 "src/sc_man_scanner.re"
{ goto std1; } { goto std1; }
#line 4187 "src/sc_man_scanner.h" #line 4189 "src/sc_man_scanner.h"
yy635: yy635:
++YYCURSOR; ++YYCURSOR;
#line 247 "src/sc_man_scanner.re" #line 247 "src/sc_man_scanner.re"
{ goto newline; } { goto newline; }
#line 4192 "src/sc_man_scanner.h" #line 4194 "src/sc_man_scanner.h"
yy637: yy637:
++YYCURSOR; ++YYCURSOR;
#line 248 "src/sc_man_scanner.re" #line 248 "src/sc_man_scanner.re"
{ goto string; } { goto string; }
#line 4197 "src/sc_man_scanner.h" #line 4199 "src/sc_man_scanner.h"
yy639: yy639:
++YYCURSOR; ++YYCURSOR;
#line 250 "src/sc_man_scanner.re" #line 250 "src/sc_man_scanner.re"
{ goto negative_check; } { goto negative_check; }
#line 4202 "src/sc_man_scanner.h" #line 4204 "src/sc_man_scanner.h"
yy641: yy641:
++YYCURSOR; ++YYCURSOR;
if((yych = *YYCURSOR) == '.') goto yy671; if((yych = *YYCURSOR) <= '9') {
if(yych == '.') goto yy679;
if(yych <= '/') goto yy653; if(yych <= '/') goto yy653;
if(yych <= '9') goto yy669; goto yy676;
} else {
if(yych <= 'E') {
if(yych <= 'D') goto yy653;
goto yy678;
} else {
if(yych == 'e') goto yy678;
goto yy653; goto yy653;
}
}
yy642: yy642:
#line 259 "src/sc_man_scanner.re" #line 260 "src/sc_man_scanner.re"
{ goto normal_token; } { goto normal_token; }
#line 4212 "src/sc_man_scanner.h" #line 4223 "src/sc_man_scanner.h"
yy643: yy643:
yych = *++YYCURSOR; yych = *++YYCURSOR;
if(yych <= '/') goto yy632; if(yych <= '/') goto yy632;
@ -4270,103 +4281,375 @@ yy653:
} }
yy654: yy654:
++YYCURSOR; ++YYCURSOR;
#line 258 "src/sc_man_scanner.re"
{ goto normal_token; }
#line 4287 "src/sc_man_scanner.h"
yy656:
++YYCURSOR;
#line 257 "src/sc_man_scanner.re" #line 257 "src/sc_man_scanner.re"
{ goto normal_token; } { goto normal_token; }
#line 4276 "src/sc_man_scanner.h" #line 4292 "src/sc_man_scanner.h"
yy656: yy658:
++YYCURSOR; ++YYCURSOR;
#line 256 "src/sc_man_scanner.re" #line 256 "src/sc_man_scanner.re"
{ goto normal_token; } { goto normal_token; }
#line 4281 "src/sc_man_scanner.h" #line 4297 "src/sc_man_scanner.h"
yy658: yy660:
++YYCURSOR; ++YYCURSOR;
#line 255 "src/sc_man_scanner.re" #line 255 "src/sc_man_scanner.re"
{ goto normal_token; } { goto normal_token; }
#line 4286 "src/sc_man_scanner.h" #line 4302 "src/sc_man_scanner.h"
yy660: yy662:
++YYCURSOR; ++YYCURSOR;
#line 254 "src/sc_man_scanner.re" #line 254 "src/sc_man_scanner.re"
{ goto normal_token; } { goto normal_token; }
#line 4291 "src/sc_man_scanner.h" #line 4307 "src/sc_man_scanner.h"
yy662: yy664:
++YYCURSOR; ++YYCURSOR;
#line 253 "src/sc_man_scanner.re" #line 253 "src/sc_man_scanner.re"
{ goto normal_token; } { goto normal_token; }
#line 4296 "src/sc_man_scanner.h" #line 4312 "src/sc_man_scanner.h"
yy664:
++YYCURSOR;
#line 252 "src/sc_man_scanner.re"
{ goto normal_token; }
#line 4301 "src/sc_man_scanner.h"
yy666: yy666:
++YYCURSOR; yyaccept = 1;
if(YYLIMIT == YYCURSOR) YYFILL(1); YYMARKER = ++YYCURSOR;
if((YYLIMIT - YYCURSOR) < 3) YYFILL(3);
yych = *YYCURSOR; yych = *YYCURSOR;
if(yych <= 'K') {
if(yych <= 'D') {
if(yych <= '/') goto yy668; if(yych <= '/') goto yy668;
if(yych <= '9') goto yy666; if(yych <= '9') goto yy666;
} else {
if(yych <= 'E') goto yy669;
if(yych <= 'F') goto yy671;
}
} else {
if(yych <= 'e') {
if(yych <= 'L') goto yy671;
if(yych >= 'e') goto yy669;
} else {
if(yych <= 'f') goto yy671;
if(yych == 'l') goto yy671;
}
}
yy668: yy668:
#line 251 "src/sc_man_scanner.re" #line 251 "src/sc_man_scanner.re"
{ goto normal_token; } { goto normal_token; }
#line 4311 "src/sc_man_scanner.h" #line 4338 "src/sc_man_scanner.h"
yy669: yy669:
yych = *++YYCURSOR;
if(yych <= ',') {
if(yych == '+') goto yy673;
} else {
if(yych <= '-') goto yy673;
if(yych <= '/') goto yy670;
if(yych <= '9') goto yy674;
}
yy670:
YYCURSOR = YYMARKER;
if(yyaccept <= 1) {
if(yyaccept <= 0) {
goto yy632;
} else {
goto yy668;
}
} else {
goto yy642;
}
yy671:
++YYCURSOR;
yy672:
#line 252 "src/sc_man_scanner.re"
{ goto normal_token; }
#line 4364 "src/sc_man_scanner.h"
yy673:
yych = *++YYCURSOR;
if(yych <= '/') goto yy670;
if(yych >= ':') goto yy670;
yy674:
++YYCURSOR; ++YYCURSOR;
if(YYLIMIT == YYCURSOR) YYFILL(1); if(YYLIMIT == YYCURSOR) YYFILL(1);
yych = *YYCURSOR; yych = *YYCURSOR;
if(yych <= '@') { if(yych <= 'K') {
if(yych <= '-') { if(yych <= '9') {
if(yych == '\'') goto yy652; if(yych <= '/') goto yy672;
goto yy642; goto yy674;
} else { } else {
if(yych <= '.') goto yy671; if(yych == 'F') goto yy671;
if(yych <= '/') goto yy642; goto yy672;
if(yych <= '9') goto yy669;
goto yy642;
} }
} else { } else {
if(yych <= '_') { if(yych <= 'f') {
if(yych <= 'Z') goto yy652; if(yych <= 'L') goto yy671;
if(yych <= '^') goto yy642; if(yych <= 'e') goto yy672;
goto yy652; goto yy671;
} else {
if(yych == 'l') goto yy671;
goto yy672;
}
}
yy676:
++YYCURSOR;
if((YYLIMIT - YYCURSOR) < 4) YYFILL(4);
yych = *YYCURSOR;
if(yych <= 'E') {
if(yych <= '.') {
if(yych == '\'') goto yy652;
if(yych <= '-') goto yy642;
goto yy679;
} else {
if(yych <= '9') {
if(yych <= '/') goto yy642;
goto yy676;
} else {
if(yych <= '@') goto yy642;
if(yych <= 'D') goto yy652;
}
}
} else {
if(yych <= '`') {
if(yych <= 'Z') goto yy652;
if(yych == '_') goto yy652;
goto yy642;
} else {
if(yych <= 'e') {
if(yych <= 'd') goto yy652;
} else { } else {
if(yych <= '`') goto yy642;
if(yych <= 'z') goto yy652; if(yych <= 'z') goto yy652;
if(yych <= '~') goto yy642; if(yych <= '~') goto yy642;
goto yy652; goto yy652;
} }
} }
yy671: }
++YYCURSOR; yy678:
if(YYLIMIT == YYCURSOR) YYFILL(1); yyaccept = 2;
yych = *(YYMARKER = ++YYCURSOR);
if(yych <= ',') {
if(yych == '+') goto yy690;
goto yy653;
} else {
if(yych <= '-') goto yy690;
if(yych <= '/') goto yy653;
if(yych <= '9') goto yy691;
goto yy653;
}
yy679:
yyaccept = 1;
yych = *(YYMARKER = ++YYCURSOR);
if(yych == 'E') goto yy682;
if(yych == 'e') goto yy682;
goto yy681;
yy680:
yyaccept = 1;
YYMARKER = ++YYCURSOR;
if((YYLIMIT - YYCURSOR) < 3) YYFILL(3);
yych = *YYCURSOR; yych = *YYCURSOR;
yy681:
if(yych <= 'K') {
if(yych <= 'D') {
if(yych <= '/') goto yy668; if(yych <= '/') goto yy668;
if(yych <= '9') goto yy671; if(yych <= '9') goto yy680;
goto yy668; goto yy668;
yy673: } else {
if(yych <= 'E') goto yy686;
if(yych <= 'F') goto yy671;
goto yy668;
}
} else {
if(yych <= 'e') {
if(yych <= 'L') goto yy671;
if(yych <= 'd') goto yy668;
goto yy686;
} else {
if(yych <= 'f') goto yy671;
if(yych == 'l') goto yy671;
goto yy668;
}
}
yy682:
yych = *++YYCURSOR;
if(yych <= ',') {
if(yych != '+') goto yy670;
} else {
if(yych <= '-') goto yy683;
if(yych <= '/') goto yy670;
if(yych <= '9') goto yy684;
goto yy670;
}
yy683:
yych = *++YYCURSOR;
if(yych <= '/') goto yy670;
if(yych >= ':') goto yy670;
yy684:
++YYCURSOR; ++YYCURSOR;
if(YYLIMIT == YYCURSOR) YYFILL(1); if(YYLIMIT == YYCURSOR) YYFILL(1);
yych = *YYCURSOR; yych = *YYCURSOR;
yy674: if(yych <= 'K') {
if(yych <= '9') {
if(yych <= '/') goto yy672;
goto yy684;
} else {
if(yych == 'F') goto yy671;
goto yy672;
}
} else {
if(yych <= 'f') {
if(yych <= 'L') goto yy671;
if(yych <= 'e') goto yy672;
goto yy671;
} else {
if(yych == 'l') goto yy671;
goto yy672;
}
}
yy686:
yych = *++YYCURSOR;
if(yych <= ',') {
if(yych != '+') goto yy670;
} else {
if(yych <= '-') goto yy687;
if(yych <= '/') goto yy670;
if(yych <= '9') goto yy688;
goto yy670;
}
yy687:
yych = *++YYCURSOR;
if(yych <= '/') goto yy670;
if(yych >= ':') goto yy670;
yy688:
++YYCURSOR;
if(YYLIMIT == YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if(yych <= 'K') {
if(yych <= '9') {
if(yych <= '/') goto yy672;
goto yy688;
} else {
if(yych == 'F') goto yy671;
goto yy672;
}
} else {
if(yych <= 'f') {
if(yych <= 'L') goto yy671;
if(yych <= 'e') goto yy672;
goto yy671;
} else {
if(yych == 'l') goto yy671;
goto yy672;
}
}
yy690:
yych = *++YYCURSOR;
if(yych <= '/') goto yy670;
if(yych <= '9') goto yy694;
goto yy670;
yy691:
++YYCURSOR;
if((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR;
if(yych <= 'Z') {
if(yych <= '@') {
if(yych <= '\'') {
if(yych <= '&') goto yy672;
goto yy652;
} else {
if(yych <= '/') goto yy672;
if(yych <= '9') goto yy691;
goto yy672;
}
} else {
if(yych <= 'F') {
if(yych <= 'E') goto yy652;
} else {
if(yych != 'L') goto yy652;
}
}
} else {
if(yych <= 'f') {
if(yych <= '_') {
if(yych <= '^') goto yy672;
goto yy652;
} else {
if(yych <= '`') goto yy672;
if(yych <= 'e') goto yy652;
}
} else {
if(yych <= 'l') {
if(yych <= 'k') goto yy652;
} else {
if(yych <= 'z') goto yy652;
if(yych <= '~') goto yy672;
goto yy652;
}
}
}
yych = *++YYCURSOR;
if(yych <= 'Z') {
if(yych <= '/') {
if(yych == '\'') goto yy652;
goto yy672;
} else {
if(yych <= '9') goto yy652;
if(yych <= '@') goto yy672;
goto yy652;
}
} else {
if(yych <= '`') {
if(yych == '_') goto yy652;
goto yy672;
} else {
if(yych <= 'z') goto yy652;
if(yych <= '~') goto yy672;
goto yy652;
}
}
yy694:
++YYCURSOR;
if(YYLIMIT == YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
if(yych <= 'K') {
if(yych <= '9') {
if(yych <= '/') goto yy672;
goto yy694;
} else {
if(yych == 'F') goto yy671;
goto yy672;
}
} else {
if(yych <= 'f') {
if(yych <= 'L') goto yy671;
if(yych <= 'e') goto yy672;
goto yy671;
} else {
if(yych == 'l') goto yy671;
goto yy672;
}
}
yy696:
++YYCURSOR;
if(YYLIMIT == YYCURSOR) YYFILL(1);
yych = *YYCURSOR;
yy697:
if(yych == 0x0A) goto yy634; if(yych == 0x0A) goto yy634;
if(yych <= ' ') goto yy673; if(yych <= ' ') goto yy696;
goto yy634; goto yy634;
yy675: yy698:
++YYCURSOR; ++YYCURSOR;
if(YYLIMIT == YYCURSOR) YYFILL(1); if(YYLIMIT == YYCURSOR) YYFILL(1);
yych = *YYCURSOR; yych = *YYCURSOR;
if(yych == 0x0A) goto yy679; if(yych == 0x0A) goto yy702;
goto yy675; goto yy698;
yy677: yy700:
++YYCURSOR; ++YYCURSOR;
#line 243 "src/sc_man_scanner.re" #line 243 "src/sc_man_scanner.re"
{ goto comment; } { goto comment; }
#line 4363 "src/sc_man_scanner.h" #line 4646 "src/sc_man_scanner.h"
yy679: yy702:
++YYCURSOR; ++YYCURSOR;
#line 244 "src/sc_man_scanner.re" #line 244 "src/sc_man_scanner.re"
{ goto newline; } { goto newline; }
#line 4368 "src/sc_man_scanner.h" #line 4651 "src/sc_man_scanner.h"
} }
#line 262 "src/sc_man_scanner.re" #line 263 "src/sc_man_scanner.re"
} }
@ -4394,22 +4677,22 @@ negative_check:
comment: comment:
#line 4398 "src/sc_man_scanner.h" #line 4681 "src/sc_man_scanner.h"
{ {
YYCTYPE yych; YYCTYPE yych;
if((YYLIMIT - YYCURSOR) < 2) YYFILL(2); if((YYLIMIT - YYCURSOR) < 2) YYFILL(2);
yych = *YYCURSOR; yych = *YYCURSOR;
if(yych == 0x0A) goto yy685; if(yych == 0x0A) goto yy708;
if(yych != '*') goto yy687; if(yych != '*') goto yy710;
++YYCURSOR; ++YYCURSOR;
if((yych = *YYCURSOR) == '/') goto yy688; if((yych = *YYCURSOR) == '/') goto yy711;
yy684: yy707:
#line 311 "src/sc_man_scanner.re" #line 312 "src/sc_man_scanner.re"
{ goto comment; } { goto comment; }
#line 4410 "src/sc_man_scanner.h" #line 4693 "src/sc_man_scanner.h"
yy685: yy708:
++YYCURSOR; ++YYCURSOR;
#line 300 "src/sc_man_scanner.re" #line 301 "src/sc_man_scanner.re"
{ {
if (YYCURSOR >= YYLIMIT) if (YYCURSOR >= YYLIMIT)
{ {
@ -4421,13 +4704,13 @@ yy685:
Crossed = true; Crossed = true;
goto comment; goto comment;
} }
#line 4425 "src/sc_man_scanner.h" #line 4708 "src/sc_man_scanner.h"
yy687: yy710:
yych = *++YYCURSOR; yych = *++YYCURSOR;
goto yy684; goto yy707;
yy688: yy711:
++YYCURSOR; ++YYCURSOR;
#line 290 "src/sc_man_scanner.re" #line 291 "src/sc_man_scanner.re"
{ {
if (YYCURSOR >= YYLIMIT) if (YYCURSOR >= YYLIMIT)
{ {
@ -4437,9 +4720,9 @@ yy688:
} }
goto std1; goto std1;
} }
#line 4441 "src/sc_man_scanner.h" #line 4724 "src/sc_man_scanner.h"
} }
#line 312 "src/sc_man_scanner.re" #line 313 "src/sc_man_scanner.re"
newline: newline:

View file

@ -249,6 +249,7 @@ std2:
[-] { goto negative_check; } [-] { goto negative_check; }
((D* [.] D+) | (D+ [.] D*)) { goto normal_token; } /* decimal number */ ((D* [.] D+) | (D+ [.] D*)) { goto normal_token; } /* decimal number */
(D+ E FS?) | (D* "." D+ E? FS?) | (D+ "." D* E? FS?) { goto normal_token; } /* float with exponent */
"::" { goto normal_token; } "::" { goto normal_token; }
"&&" { goto normal_token; } "&&" { goto normal_token; }
"==" { goto normal_token; } "==" { goto normal_token; }

File diff suppressed because it is too large Load diff