diff --git a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/0a2c7a92-eff0-4816-a47e-8d884bcc0d43.vsidx b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/0a2c7a92-eff0-4816-a47e-8d884bcc0d43.vsidx deleted file mode 100644 index f1b523cd..00000000 Binary files a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/0a2c7a92-eff0-4816-a47e-8d884bcc0d43.vsidx and /dev/null differ diff --git a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/2610d520-9e62-496b-8afd-b26efd75bf79.vsidx b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/2610d520-9e62-496b-8afd-b26efd75bf79.vsidx deleted file mode 100644 index b5179b29..00000000 Binary files a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/2610d520-9e62-496b-8afd-b26efd75bf79.vsidx and /dev/null differ diff --git a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/3f6f6bc5-ce17-45c0-9876-7e489ce728aa.vsidx b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/3f6f6bc5-ce17-45c0-9876-7e489ce728aa.vsidx new file mode 100644 index 00000000..c808dbfa Binary files /dev/null and b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/3f6f6bc5-ce17-45c0-9876-7e489ce728aa.vsidx differ diff --git a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/4ba93158-180e-4592-bddc-9e888cd30b8e.vsidx b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/4ba93158-180e-4592-bddc-9e888cd30b8e.vsidx new file mode 100644 index 00000000..71fefe3d Binary files /dev/null and b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/4ba93158-180e-4592-bddc-9e888cd30b8e.vsidx differ diff --git a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/6dab91eb-fca0-439f-802d-3e6ec32245bd.vsidx b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/6dab91eb-fca0-439f-802d-3e6ec32245bd.vsidx deleted file mode 100644 index 66e7be2f..00000000 Binary files a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/6dab91eb-fca0-439f-802d-3e6ec32245bd.vsidx and /dev/null differ diff --git a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/cb931ce2-7bd0-4c66-acec-2d4d11008b4e.vsidx b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/cb931ce2-7bd0-4c66-acec-2d4d11008b4e.vsidx new file mode 100644 index 00000000..c3d7d74c Binary files /dev/null and b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/FileContentIndex/cb931ce2-7bd0-4c66-acec-2d4d11008b4e.vsidx differ diff --git a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/v17/.suo b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/v17/.suo index 84aac3a0..ad922863 100644 Binary files a/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/v17/.suo and b/源代码/.Net Framework/Stg_Sharp/.vs/Stg_Sharp/v17/.suo differ diff --git a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Control/Create.cs b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Control/Create.cs index 497740b1..afef40e0 100644 --- a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Control/Create.cs +++ b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Control/Create.cs @@ -13,7 +13,7 @@ namespace StgSharp.Control { static public class Create { - + private static LinkedObject cache; @@ -91,13 +91,12 @@ namespace StgSharp.Control PointCommon p = new PointCommon(beginX, beginY, angle,Pool.tickCounter); p.XVelocity = x; p.YVelocity = y; - Pool.pointPool.mainCotainer.Add(p); + Pool.pointContainer.Add(p); } public static void Circle(IPoint c, float r) - { - Pool. + { } } } diff --git a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Control/Pool.cs b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Control/Pool.cs index dfa8d979..0216e482 100644 --- a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Control/Pool.cs +++ b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Control/Pool.cs @@ -24,17 +24,25 @@ namespace StgSharp.Control = new Collector(side.right,600); - internal static IContainer entityContainer - = new EntityContainer(topCollector,bottomCollector,leftCollector,rightCollector) ; + internal static Counter entityCounter + =new Counter(); + internal static LinkedList entityContainer + = new LinkedList(entityCounter); - internal static IContainer bulletContainer - = new EntityContainer(topCollector, bottomCollector, leftCollector, rightCollector); + internal static Counter bulletCounter + =new Counter(); + internal static LinkedList bulletContainer + = new LinkedList(bulletCounter); - internal static IContainer geometryContainer - = new GeometryContainer(topCollector, bottomCollector, leftCollector, rightCollector) ; + internal static Counter gemoetryCounter + =new Counter(); + internal static LinkedList geometryContainer + = new LinkedList(gemoetryCounter); - internal static IContainer pointContainer - = new PointContainer(topCollector, bottomCollector, leftCollector, rightCollector) ; + internal static Counter pointCounter + =new Counter(); + internal static LinkedList pointContainer + = new LinkedList(pointCounter); static Pool() { diff --git a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Entity/Bullet.cs b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Entity/Bullet.cs index 55e3ac66..99fb38b2 100644 --- a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Entity/Bullet.cs +++ b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Entity/Bullet.cs @@ -10,7 +10,7 @@ namespace StgSharp.Entity { public class Bullet : LinkedObject { - private IPoint _location; + internal IPoint _location; public IPoint Location { @@ -18,8 +18,8 @@ namespace StgSharp.Entity set { _location = value; } } - private float _x; - private float _y; + internal float _x; + internal float _y; public float X { diff --git a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Game/CoreInfo.cs b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Game/CoreInfo.cs index 15166dbe..e7caec9d 100644 --- a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Game/CoreInfo.cs +++ b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Game/CoreInfo.cs @@ -11,6 +11,10 @@ namespace StgSharp.Game public static readonly string _coreSignature; public static readonly string _coreName; + + public static readonly uint _pointLimit = 2048 ; + public static readonly uint _geometryLimit = 512 ; + internal string CoreEdition { get { return _coreName; } diff --git a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Logic/Counter.cs b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Logic/Counter.cs index ee760e0c..21b9826b 100644 --- a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Logic/Counter.cs +++ b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Logic/Counter.cs @@ -16,6 +16,14 @@ namespace StgSharp.Logic set { _value = value; } } + private T _max; + + public T Max + { + get { return _max; } + set { _max = value; } + } + public Counter() { @@ -23,12 +31,14 @@ namespace StgSharp.Logic public void Increase(T deltaValue) { + //_value += deltaValue; } public void Decrease(T deltaValue) { //_value -= deltaValue; + } } } diff --git a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Logic/LinkedList.cs b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Logic/LinkedList.cs index 117f8b74..83f71c1b 100644 --- a/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Logic/LinkedList.cs +++ b/源代码/.Net Framework/Stg_Sharp/Stg_Sharp/Logic/LinkedList.cs @@ -35,10 +35,13 @@ namespace StgSharp.Logic set { _amountCounter = value; } } - //构造器 - public LinkedList() + /// + /// 构造一个专用链表,并将计数器传入 + /// + /// + public LinkedList(Counter counter) { - this._amountCounter = new Counter(); + _amountCounter = counter; _amountCounter.Value = 0; _heading = null; } @@ -93,6 +96,8 @@ namespace StgSharp.Logic _amountCounter.Value--; } + + /// /// 该方法用于防止传入不属于该链表的实例。 ///