Modified weapon scripts to eliminate specialized projectile behavior - allows charged weapons to have projectiles and modify weapon stats when charged Added machine gun weapon & VFX Moved third party code to Plugins folder to improve compile times
52 lines
No EOL
1.5 KiB
C#
52 lines
No EOL
1.5 KiB
C#
using System;
|
|
using Microsoft.Msagl.Core.DataStructures;
|
|
using Microsoft.Msagl.Core.Geometry;
|
|
using Microsoft.Msagl.Routing.Visibility;
|
|
using System.Diagnostics;
|
|
|
|
namespace Microsoft.Msagl.Routing.Spline.Bundling {
|
|
[DebuggerDisplay("({SourcePoint.X},{SourcePoint.Y})->({TargetPoint.X},{TargetPoint.Y})")]
|
|
internal class SdBoneEdge {
|
|
internal readonly VisibilityEdge VisibilityEdge;
|
|
internal readonly SdVertex Source;
|
|
internal readonly SdVertex Target;
|
|
int numberOfPassedPaths;
|
|
|
|
internal SdBoneEdge(VisibilityEdge visibilityEdge, SdVertex source, SdVertex target) {
|
|
VisibilityEdge = visibilityEdge;
|
|
Source = source;
|
|
Target = target;
|
|
}
|
|
|
|
internal Point TargetPoint {
|
|
get { return Target.Point; }
|
|
}
|
|
|
|
internal Point SourcePoint {
|
|
get { return Source.Point; }
|
|
}
|
|
|
|
internal bool IsOccupied {
|
|
get { return numberOfPassedPaths > 0; }
|
|
}
|
|
|
|
internal Set<CdtEdge> CrossedCdtEdges { get; set; }
|
|
|
|
internal bool IsPassable {
|
|
get {
|
|
return Target.IsTargetOfRouting || Source.IsSourceOfRouting ||
|
|
VisibilityEdge.IsPassable == null ||
|
|
VisibilityEdge.IsPassable();
|
|
}
|
|
}
|
|
|
|
internal void AddOccupiedEdge() {
|
|
numberOfPassedPaths++;
|
|
}
|
|
|
|
internal void RemoveOccupiedEdge() {
|
|
numberOfPassedPaths--;
|
|
Debug.Assert(numberOfPassedPaths >= 0);
|
|
}
|
|
}
|
|
} |