- sync source with latest GZDoom:

Includes:
- Made the move tried from checking missile spawns ignore drop off height. This solves the Voodoo Gun ghostly civilian issue.
- Fixed: the NOTELEPORT flag is removed from Dehacked missiles which lose the MISSILE flag. This caused problems with certain special effects based on dehacked spawn cubes.
- Fixed: all Boom silent teleporters preserve relative height.
- support for palette independent particle colors if the renderer can handle them.


SVN r3329 (trunk)
This commit is contained in:
Christoph Oelckers 2011-12-06 08:36:28 +00:00
commit 893455ef61
20 changed files with 488 additions and 339 deletions

View file

@ -215,13 +215,15 @@ void P_InitEffects ()
P_InitParticles();
while (color->color)
{
*(color->color) = ColorMatcher.Pick (color->r, color->g, color->b);
*(color->color) = (MAKERGB(color->r, color->g, color->b)
| (ColorMatcher.Pick (color->r, color->g, color->b) << 24));
color++;
}
int kind = gameinfo.defaultbloodparticlecolor;
blood1 = ColorMatcher.Pick(RPART(kind), GPART(kind), BPART(kind));
blood2 = ColorMatcher.Pick(RPART(kind)/3, GPART(kind)/3, BPART(kind)/3);
int kind3 = MAKERGB(RPART(kind)/3, GPART(kind)/3, BPART(kind)/3);
blood1 = kind | (ColorMatcher.Pick(RPART(kind), GPART(kind), BPART(kind)) << 24);
blood2 = kind3 | (ColorMatcher.Pick(RPART(kind3), GPART(kind3), BPART(kind3)) << 24);
}
@ -520,8 +522,9 @@ void P_DrawSplash2 (int count, fixed_t x, fixed_t y, fixed_t z, angle_t angle, i
color2 = grey1;
break;
default: // colorized blood
color1 = ColorMatcher.Pick(RPART(kind), GPART(kind), BPART(kind));
color2 = ColorMatcher.Pick(RPART(kind)>>1, GPART(kind)>>1, BPART(kind)>>1);
color1 = kind | (ColorMatcher.Pick(RPART(kind), GPART(kind), BPART(kind)) << 24);
color2 = MAKERGB((kind)>>1, GPART(kind)>>1, BPART(kind)>>1)
| (ColorMatcher.Pick(RPART(kind)>>1, GPART(kind)>>1, BPART(kind)>>1) << 24);
break;
}
@ -598,7 +601,7 @@ void P_DrawRailTrail (AActor *source, const FVector3 &start, const FVector3 &end
{
// Only consider sound in 2D (for now, anyway)
// [BB] You have to devide by lengthsquared here, not multiply with it.
// [BB] You have to divide by lengthsquared here, not multiply with it.
r = ((start.Y - FIXED2FLOAT(mo->y)) * (-dir.Y) - (start.X - FIXED2FLOAT(mo->x)) * (dir.X)) / lengthsquared;
r = clamp<double>(r, 0., 1.);
@ -646,7 +649,7 @@ void P_DrawRailTrail (AActor *source, const FVector3 &start, const FVector3 &end
FVector3 spiral_step = step * r_rail_spiralsparsity;
int spiral_steps = steps * r_rail_spiralsparsity;
color1 = color1 == 0 ? -1 : ColorMatcher.Pick(RPART(color1), GPART(color1), BPART(color1));
color1 = color1 == 0 ? -1 : color1 | (ColorMatcher.Pick(RPART(color1), GPART(color1), BPART(color1)) <<24);
pos = start;
deg = FAngle(270);
for (i = spiral_steps; i; i--)
@ -699,7 +702,7 @@ void P_DrawRailTrail (AActor *source, const FVector3 &start, const FVector3 &end
FVector3 trail_step = step * r_rail_trailsparsity;
int trail_steps = steps * r_rail_trailsparsity;
color2 = color2 == 0 ? -1 : ColorMatcher.Pick(RPART(color2), GPART(color2), BPART(color2));
color2 = color2 == 0 ? -1 : color2 | (ColorMatcher.Pick(RPART(color2), GPART(color2), BPART(color2)) <<24);
FVector3 diff(0, 0, 0);
pos = start;