| @@ -6,8 +6,6 @@ namespace GameClass.GameObj | |||||
| { | { | ||||
| public class Student : Character | public class Student : Character | ||||
| { | { | ||||
| private readonly object beAttackedLock = new(); | |||||
| /// <summary> | /// <summary> | ||||
| /// 遭受攻击 | /// 遭受攻击 | ||||
| /// </summary> | /// </summary> | ||||
| @@ -10,8 +10,10 @@ namespace GameClass.GameObj | |||||
| { | { | ||||
| public partial class Character : Moveable, ICharacter // 负责人LHR摆烂终了 | public partial class Character : Moveable, ICharacter // 负责人LHR摆烂终了 | ||||
| { | { | ||||
| #region 装弹、攻击相关的基本属性及方法 | |||||
| protected readonly object beAttackedLock = new(); | |||||
| #region 装弹攻击相关的基本属性及方法 | |||||
| /// <summary> | /// <summary> | ||||
| /// 装弹冷却 | /// 装弹冷却 | ||||
| /// </summary> | /// </summary> | ||||
| @@ -59,13 +59,10 @@ namespace Gaming | |||||
| if (indexing == GameData.maxNumOfPropInPropInventory) | if (indexing == GameData.maxNumOfPropInPropInventory) | ||||
| return false; | return false; | ||||
| Prop? pickProp = new NullProp(); | |||||
| Prop pickProp = new NullProp(); | |||||
| if (propType == PropType.Null) // 自动检查有无道具可捡 | if (propType == PropType.Null) // 自动检查有无道具可捡 | ||||
| { | { | ||||
| pickProp = (Prop?)gameMap.OneInTheSameCell(player.Position, GameObjType.Prop); | |||||
| if (pickProp != null) | |||||
| player.PropInventory[indexing] = pickProp; | |||||
| else player.PropInventory[indexing] = pickProp = new NullProp(); | |||||
| pickProp = player.PropInventory[indexing] = ((Prop?)gameMap.OneInTheSameCell(player.Position, GameObjType.Prop)) ?? new NullProp(); | |||||
| } | } | ||||
| else | else | ||||
| { | { | ||||
| @@ -253,11 +253,11 @@ | |||||
| - 窗必须在两个墙之间,另外两侧不能为墙 | - 窗必须在两个墙之间,另外两侧不能为墙 | ||||
| ### 箱子 | ### 箱子 | ||||
| - *监管者和求生者都能与箱子交互,同一时刻只允许一人进行开启* | |||||
| - 监管者和求生者都能与箱子交互,同一时刻只允许一人进行开启 | |||||
| - 开启箱子有不同概率获得不同道具。 | - 开启箱子有不同概率获得不同道具。 | ||||
| - *开启箱子的基础持续时间为10秒。* | |||||
| - *未开启完成的箱子在下一次需要重新开始开启。* | |||||
| - *箱子开启后其中道具才可以被观测和拿取* | |||||
| - 开启箱子的基础持续时间为10秒。 | |||||
| - 未开启完成的箱子在下一次需要重新开始开启。 | |||||
| - 箱子开启后其中道具才可以被观测和拿取 | |||||
| - [箱子道具不刷新] | - [箱子道具不刷新] | ||||
| - [箱子不可被关闭] | - [箱子不可被关闭] | ||||
| - [箱子内道具最多两个] | - [箱子内道具最多两个] | ||||
| @@ -294,4 +294,4 @@ | |||||
| ### 救人 | ### 救人 | ||||
| - 一般情况下,救人时间为1秒。 | - 一般情况下,救人时间为1秒。 | ||||
| - *不能两人同时救一个人* | |||||
| - 不能两人同时救一个人 | |||||