mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-22 04:21:23 +00:00
Adapt setup of PolyObject move action
This commit is contained in:
parent
8e550cd423
commit
b3a553513a
3 changed files with 40 additions and 8 deletions
|
@ -1765,6 +1765,7 @@ udmf
|
|||
title = "Return delay";
|
||||
}
|
||||
}
|
||||
|
||||
481
|
||||
{
|
||||
title = "Door Swing";
|
||||
|
@ -1789,6 +1790,31 @@ udmf
|
|||
}
|
||||
}
|
||||
|
||||
482
|
||||
{
|
||||
title = "Move";
|
||||
prefix = "(482)";
|
||||
arg0
|
||||
{
|
||||
title = "PolyObject ID";
|
||||
type = 14;
|
||||
}
|
||||
arg1
|
||||
{
|
||||
title = "Speed";
|
||||
}
|
||||
arg2
|
||||
{
|
||||
title = "Distance";
|
||||
}
|
||||
arg3
|
||||
{
|
||||
title = "Override?";
|
||||
type = 11;
|
||||
enum = "noyes";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
light
|
||||
{
|
||||
|
|
|
@ -2924,6 +2924,14 @@ static void P_ConvertBinaryMap(void)
|
|||
lines[i].args[2] = sides[lines[i].sidenum[0]].rowoffset >> FRACBITS;
|
||||
lines[i].args[3] = (lines[i].sidenum[1] == 0xffff) ? 0 : (sides[lines[i].sidenum[1]].textureoffset >> FRACBITS);
|
||||
break;
|
||||
case 482: //PolyObject: Move
|
||||
case 483: //PolyObject: Move, override
|
||||
lines[i].args[0] = lines[i].tag;
|
||||
lines[i].args[1] = sides[lines[i].sidenum[0]].textureoffset >> FRACBITS;
|
||||
lines[i].args[2] = sides[lines[i].sidenum[0]].rowoffset >> FRACBITS;
|
||||
lines[i].args[3] = (lines[i].special == 483);
|
||||
lines[i].special = 482;
|
||||
break;
|
||||
case 606: //Colormap
|
||||
lines[i].args[0] = lines[i].tag;
|
||||
break;
|
||||
|
|
10
src/p_spec.c
10
src/p_spec.c
|
@ -1108,12 +1108,11 @@ static boolean PolyMove(line_t *line)
|
|||
{
|
||||
polymovedata_t pmd;
|
||||
|
||||
pmd.polyObjNum = line->tag;
|
||||
pmd.speed = sides[line->sidenum[0]].textureoffset / 8;
|
||||
pmd.polyObjNum = line->args[0];
|
||||
pmd.speed = line->args[1] << (FRACBITS - 3);
|
||||
pmd.angle = R_PointToAngle2(line->v1->x, line->v1->y, line->v2->x, line->v2->y);
|
||||
pmd.distance = sides[line->sidenum[0]].rowoffset;
|
||||
|
||||
pmd.overRide = (line->special == 483); // Polyobj_OR_Move
|
||||
pmd.distance = line->args[2] << FRACBITS;
|
||||
pmd.overRide = line->args[3]; // Polyobj_OR_Move
|
||||
|
||||
return EV_DoPolyObjMove(&pmd);
|
||||
}
|
||||
|
@ -4002,7 +4001,6 @@ static void P_ProcessLineSpecial(line_t *line, mobj_t *mo, sector_t *callsec)
|
|||
PolyDoor(line);
|
||||
break;
|
||||
case 482: // Polyobj_Move
|
||||
case 483: // Polyobj_OR_Move
|
||||
PolyMove(line);
|
||||
break;
|
||||
case 484: // Polyobj_RotateRight
|
||||
|
|
Loading…
Reference in a new issue