Merge branch 'master' into scripting
Conflicts: src/p_effect.cpp src/p_effect.h src/p_local.h src/p_map.cpp src/thingdef/thingdef_codeptr.cpp
This commit is contained in:
commit
d8ea128f38
27 changed files with 220 additions and 85 deletions
|
|
@ -1064,8 +1064,8 @@ bool PIT_CheckThing(AActor *thing, FCheckPosition &tm)
|
|||
{
|
||||
unblocking = true;
|
||||
}
|
||||
else if (abs(thing->x - tm.thing->x) < (thing->radius+tm.thing->radius)/2 &&
|
||||
abs(thing->y - tm.thing->y) < (thing->radius+tm.thing->radius)/2)
|
||||
else if (abs(thing->x - tm.thing->x) < (thing->radius+tm.thing->radius) &&
|
||||
abs(thing->y - tm.thing->y) < (thing->radius+tm.thing->radius))
|
||||
|
||||
{
|
||||
fixed_t newdist = P_AproxDistance(thing->x - tm.x, thing->y - tm.y);
|
||||
|
|
@ -4150,12 +4150,12 @@ static ETraceStatus ProcessRailHit(FTraceResults &res, void *userdata)
|
|||
//
|
||||
//
|
||||
//==========================================================================
|
||||
void P_RailAttack(AActor *source, int damage, int offset_xy, fixed_t offset_z, int color1, int color2, double maxdiff, int railflags, PClassActor *puffclass, angle_t angleoffset, angle_t pitchoffset, fixed_t distance, int duration, double sparsity, double drift, PClassActor *spawnclass, int SpiralOffset)
|
||||
void P_RailAttack(AActor *source, int damage, int offset_xy, fixed_t offset_z, int color1, int color2, double maxdiff, int railflags, const PClassActor *puffclass, angle_t angleoffset, angle_t pitchoffset, fixed_t distance, int duration, double sparsity, double drift, const PClassActor *spawnclass, int SpiralOffset)
|
||||
{
|
||||
fixed_t vx, vy, vz;
|
||||
angle_t angle, pitch;
|
||||
fixed_t x1, y1;
|
||||
FVector3 start, end;
|
||||
TVector3<double> start, end;
|
||||
FTraceResults trace;
|
||||
fixed_t shootz;
|
||||
|
||||
|
|
@ -4278,11 +4278,16 @@ void P_RailAttack(AActor *source, int damage, int offset_xy, fixed_t offset_z, i
|
|||
// Spawn a decal or puff at the point where the trace ended.
|
||||
if (trace.HitType == TRACE_HitWall)
|
||||
{
|
||||
SpawnShootDecal(source, trace);
|
||||
AActor* puff = NULL;
|
||||
|
||||
if (puffclass != NULL && puffDefaults->flags3 & MF3_ALWAYSPUFF)
|
||||
{
|
||||
P_SpawnPuff(source, puffclass, trace.X, trace.Y, trace.Z, (source->angle + angleoffset) - ANG90, 1, 0);
|
||||
puff = P_SpawnPuff(source, puffclass, trace.X, trace.Y, trace.Z, (source->angle + angleoffset) - ANG90, 1, 0);
|
||||
}
|
||||
if (puff != NULL && puffDefaults->flags7 & MF7_FORCEDECAL && puff->DecalGenerator)
|
||||
SpawnShootDecal(puff, trace);
|
||||
else
|
||||
SpawnShootDecal(source, trace);
|
||||
|
||||
}
|
||||
if (thepuff != NULL)
|
||||
|
|
@ -4302,9 +4307,9 @@ void P_RailAttack(AActor *source, int damage, int offset_xy, fixed_t offset_z, i
|
|||
}
|
||||
|
||||
// Draw the slug's trail.
|
||||
end.X = FIXED2FLOAT(trace.X);
|
||||
end.Y = FIXED2FLOAT(trace.Y);
|
||||
end.Z = FIXED2FLOAT(trace.Z);
|
||||
end.X = FIXED2DBL(trace.X);
|
||||
end.Y = FIXED2DBL(trace.Y);
|
||||
end.Z = FIXED2DBL(trace.Z);
|
||||
P_DrawRailTrail(source, start, end, color1, color2, maxdiff, railflags, spawnclass, source->angle + angleoffset, duration, sparsity, drift, SpiralOffset);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue