Merge pull request #4433 from reaperrr/laserzap-improvement

LaserZap improvements
This commit is contained in:
Matthias Mailänder
2014-01-06 13:46:17 -08:00
2 changed files with 5 additions and 1 deletions

View File

@@ -24,6 +24,7 @@ NEW:
Added support for crates to level up specific unit upgrades.
Added a new Launch.Replay=$FILEPATH parameter for OpenRA.Game.exe to instantly start watching a *.rep file.
Added HackyAI settings: ExcessPowerFactor, MinimumExcessPower, IdleBaseUnitsMaximum, RushAttackScanRadius, ProtectUnitScanRadius, RallyPointScanRadius. See the traits documentation for more information.
Added HitAnimPalette trait for LaserZap projectiles. Laser hit animations can now specify individual palettes. Defaults to effect palette.
Server:
Message of the day is now shared between all mods and a default motd.txt gets created in the user directory.
Asset Browser:

View File

@@ -23,8 +23,11 @@ namespace OpenRA.Mods.RA.Effects
public readonly int BeamWidth = 2;
public readonly int BeamDuration = 10;
public readonly bool UsePlayerColor = false;
[Desc("Laser color in (A,)R,G,B.")]
public readonly Color Color = Color.Red;
[Desc("Impact animation. Requires a regular animation with idle: sequence instead of explosion special case.")]
public readonly string HitAnim = null;
public readonly string HitAnimPalette = "effect";
public IEffect Create(ProjectileArgs args)
{
@@ -86,7 +89,7 @@ namespace OpenRA.Mods.RA.Effects
}
if (hitanim != null)
foreach (var r in hitanim.Render(target, wr.Palette("effect")))
foreach (var r in hitanim.Render(target, wr.Palette(info.HitAnimPalette)))
yield return r;
}
}