mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-28 07:02:38 +00:00
Revamp alpha setup for quicksand FOFs
This commit is contained in:
parent
cc6820187c
commit
f4e28f5cc4
4 changed files with 31 additions and 11 deletions
|
@ -2122,15 +2122,24 @@ udmf
|
||||||
}
|
}
|
||||||
arg1
|
arg1
|
||||||
{
|
{
|
||||||
title = "Ripple effect?";
|
title = "Alpha";
|
||||||
type = 11;
|
default = 255;
|
||||||
enum = "yesno";
|
|
||||||
}
|
}
|
||||||
arg2
|
arg2
|
||||||
{
|
{
|
||||||
title = "Sinking speed";
|
title = "Ripple effect?";
|
||||||
|
type = 12;
|
||||||
|
enum
|
||||||
|
{
|
||||||
|
1 = "No ripple effect";
|
||||||
|
2 = "Cut cyan flat pixels";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
arg3
|
arg3
|
||||||
|
{
|
||||||
|
title = "Sinking speed";
|
||||||
|
}
|
||||||
|
arg4
|
||||||
{
|
{
|
||||||
title = "Friction";
|
title = "Friction";
|
||||||
}
|
}
|
||||||
|
|
|
@ -3366,10 +3366,13 @@ static void P_ConvertBinaryMap(void)
|
||||||
break;
|
break;
|
||||||
case 257: //FOF: Quicksand
|
case 257: //FOF: Quicksand
|
||||||
lines[i].args[0] = lines[i].tag;
|
lines[i].args[0] = lines[i].tag;
|
||||||
|
lines[i].args[1] = 255;
|
||||||
if (!(lines[i].flags & ML_EFFECT5))
|
if (!(lines[i].flags & ML_EFFECT5))
|
||||||
lines[i].args[1] = 1; //No ripple effect
|
lines[i].args[2] |= TMFQ_NORIPPLE;
|
||||||
lines[i].args[2] = lines[i].dx >> FRACBITS; //Sinking speed
|
if (lines[i].flags & ML_EFFECT6)
|
||||||
lines[i].args[3] = lines[i].dy >> FRACBITS; //Friction
|
lines[i].args[2] |= TMFQ_SPLAT;
|
||||||
|
lines[i].args[3] = lines[i].dx >> FRACBITS; //Sinking speed
|
||||||
|
lines[i].args[4] = lines[i].dy >> FRACBITS; //Friction
|
||||||
break;
|
break;
|
||||||
case 258: //FOF: Laser
|
case 258: //FOF: Laser
|
||||||
lines[i].args[0] = lines[i].tag;
|
lines[i].args[0] = lines[i].tag;
|
||||||
|
|
10
src/p_spec.c
10
src/p_spec.c
|
@ -6915,14 +6915,16 @@ void P_SpawnSpecials(boolean fromnetsave)
|
||||||
}
|
}
|
||||||
case 257: // Quicksand
|
case 257: // Quicksand
|
||||||
ffloorflags = FF_EXISTS|FF_QUICKSAND|FF_RENDERALL|FF_ALLSIDES|FF_CUTSPRITES;
|
ffloorflags = FF_EXISTS|FF_QUICKSAND|FF_RENDERALL|FF_ALLSIDES|FF_CUTSPRITES;
|
||||||
if (!(lines[i].args[1]))
|
if (!(lines[i].args[2] & TMFQ_NORIPPLE))
|
||||||
ffloorflags |= FF_RIPPLE;
|
ffloorflags |= FF_RIPPLE;
|
||||||
|
if (lines[i].args[2] & TMFQ_SPLAT)
|
||||||
|
ffloorflags |= FF_SPLAT;
|
||||||
|
|
||||||
for (s = -1; (s = P_FindSectorFromTag(lines[i].args[0], s)) >= 0 ;)
|
for (s = -1; (s = P_FindSectorFromTag(lines[i].args[0], s)) >= 0 ;)
|
||||||
{
|
{
|
||||||
ffloor_t *fflr = P_AddFakeFloor(§ors[s], lines[i].frontsector, lines + i, 0xff, ffloorflags, secthinkers);
|
ffloor_t *fflr = P_AddFakeFloor(§ors[s], lines[i].frontsector, lines + i, lines[i].args[1], ffloorflags, secthinkers);
|
||||||
fflr->sinkspeed = abs(lines[i].args[2]) << (FRACBITS - 1);
|
fflr->sinkspeed = abs(lines[i].args[3]) << (FRACBITS - 1);
|
||||||
fflr->friction = abs(lines[i].args[3]) << (FRACBITS - 6);
|
fflr->friction = abs(lines[i].args[4]) << (FRACBITS - 6);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|
|
@ -97,6 +97,12 @@ typedef enum
|
||||||
TMFB_ONLYBOTTOM = 1<<2,
|
TMFB_ONLYBOTTOM = 1<<2,
|
||||||
} textmapfofbustflags_t;
|
} textmapfofbustflags_t;
|
||||||
|
|
||||||
|
typedef enum
|
||||||
|
{
|
||||||
|
TMFQ_NORIPPLE = 1,
|
||||||
|
TMFQ_SPLAT = 1<<1,
|
||||||
|
} textmapfofquicksandflags_t;
|
||||||
|
|
||||||
typedef enum
|
typedef enum
|
||||||
{
|
{
|
||||||
TMFL_NOBOSSES = 1,
|
TMFL_NOBOSSES = 1,
|
||||||
|
|
Loading…
Reference in a new issue