mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-13 07:57:58 +00:00
- removed R_PointToAngle2 call in P_Setup.cpp.
- removed long inactive node saving code in p_writemap.cpp. If this file is ever made operational again it will be with UDMF output.
This commit is contained in:
parent
046ee3e803
commit
96a02f922d
2 changed files with 1 additions and 63 deletions
|
@ -1315,7 +1315,7 @@ void P_LoadSegs (MapData * map)
|
||||||
// off, then move one vertex. This may seem insignificant, but one degree
|
// off, then move one vertex. This may seem insignificant, but one degree
|
||||||
// errors _can_ cause firelines.
|
// errors _can_ cause firelines.
|
||||||
|
|
||||||
ptp_angle = R_PointToAngle2 (li->v1->fixX(), li->v1->fixY(), li->v2->fixX(), li->v2->fixY());
|
ptp_angle = (li->v2->fPos() - li->v1->fPos()).Angle().BAMs();
|
||||||
dis = 0;
|
dis = 0;
|
||||||
delta_angle = (absangle(ptp_angle-(segangle<<16))>>ANGLETOFINESHIFT)*360/FINEANGLES;
|
delta_angle = (absangle(ptp_angle-(segangle<<16))>>ANGLETOFINESHIFT)*360/FINEANGLES;
|
||||||
|
|
||||||
|
|
|
@ -177,79 +177,17 @@ static int WriteVERTEXES (FILE *file)
|
||||||
|
|
||||||
static int WriteSEGS (FILE *file)
|
static int WriteSEGS (FILE *file)
|
||||||
{
|
{
|
||||||
#if 0
|
|
||||||
mapseg_t ms;
|
|
||||||
|
|
||||||
ms.offset = 0; // unused by ZDoom, so just leave it 0
|
|
||||||
for (int i = 0; i < numsegs; ++i)
|
|
||||||
{
|
|
||||||
if (segs[i].linedef!=NULL)
|
|
||||||
{
|
|
||||||
ms.v1 = LittleShort(short(segs[i].v1 - vertexes));
|
|
||||||
ms.v2 = LittleShort(short(segs[i].v2 - vertexes));
|
|
||||||
ms.linedef = LittleShort(short(segs[i].linedef - lines));
|
|
||||||
ms.side = segs[i].sidedef == segs[i].linedef->sidedef[0] ? 0 : LittleShort((short)1);
|
|
||||||
ms.angle = LittleShort(short(R_PointToAngle2 (segs[i].v1->fixX(), segs[i].v1->fixY(), segs[i].v2->fixX(), segs[i].v2->fixY())>>16));
|
|
||||||
fwrite (&ms, sizeof(ms), 1, file);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return numsegs * sizeof(ms);
|
|
||||||
#else
|
|
||||||
return 0;
|
return 0;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int WriteSSECTORS (FILE *file)
|
static int WriteSSECTORS (FILE *file)
|
||||||
{
|
{
|
||||||
#if 0
|
|
||||||
mapsubsector_t mss;
|
|
||||||
|
|
||||||
for (int i = 0; i < numsubsectors; ++i)
|
|
||||||
{
|
|
||||||
mss.firstseg = LittleShort((WORD)subsectors[i].firstline);
|
|
||||||
mss.numsegs = LittleShort((WORD)subsectors[i].numlines);
|
|
||||||
fwrite (&mss, sizeof(mss), 1, file);
|
|
||||||
}
|
|
||||||
return numsubsectors * sizeof(mss);
|
|
||||||
#else
|
|
||||||
return 0;
|
return 0;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int WriteNODES (FILE *file)
|
static int WriteNODES (FILE *file)
|
||||||
{
|
{
|
||||||
#if 0
|
|
||||||
mapnode_t mn;
|
|
||||||
|
|
||||||
for (int i = 0; i < numnodes; ++i)
|
|
||||||
{
|
|
||||||
mn.x = LittleShort(short(nodes[i].x >> FRACBITS));
|
|
||||||
mn.y = LittleShort(short(nodes[i].y >> FRACBITS));
|
|
||||||
mn.dx = LittleShort(short(nodes[i].dx >> FRACBITS));
|
|
||||||
mn.dy = LittleShort(short(nodes[i].dy >> FRACBITS));
|
|
||||||
for (int j = 0; j < 2; ++j)
|
|
||||||
{
|
|
||||||
for (int k = 0; k < 4; ++k)
|
|
||||||
{
|
|
||||||
mn.bbox[j][k] = LittleShort(short(nodes[i].bbox[j][k] >> FRACBITS));
|
|
||||||
}
|
|
||||||
WORD child;
|
|
||||||
if ((size_t)nodes[i].children[j] & 1)
|
|
||||||
{
|
|
||||||
child = mapnode_t::NF_SUBSECTOR | WORD((subsector_t *)((BYTE *)nodes[i].children[j] - 1) - subsectors);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
child = WORD((node_t *)nodes[i].children[j] - nodes);
|
|
||||||
}
|
|
||||||
mn.children[j] = LittleShort(child);
|
|
||||||
}
|
|
||||||
fwrite (&mn, sizeof(mn), 1, file);
|
|
||||||
}
|
|
||||||
return numnodes * sizeof(mn);
|
|
||||||
#else
|
|
||||||
return 0;
|
return 0;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int WriteSECTORS (FILE *file)
|
static int WriteSECTORS (FILE *file)
|
||||||
|
|
Loading…
Reference in a new issue