private void StartAction() { // 根据Action增加相应属性 foreach (SelectedActionButton s in m_ActionListBtns) { if (s.action != null) { Widget.AddProperty(GlobalManager.Instance.player, s.action); // 舍友邀请后一同行动 if (GlobalManager.Instance.Invitation != 0) { Widget.AddProperty(GlobalManager.Instance.roommates[GlobalManager.Instance.Invitation - 1], s.action); if (GlobalManager.Instance.player.stateDic.ContainsKey(StateName.Help1)) { // 劳动+大于1体力的 增加亲密度值为 (行动的消耗体力值+减免的值) *2 if (s.action.Type == ActionType.Labor && s.action.Consume > 1) { GlobalManager.Instance.roommates[GlobalManager.Instance.Invitation - 1].RelationShip += ((s.action.Consume + s.action.ConsumeBonus) * 2); } else { // 否则增加 行动的消耗体力值 *2 GlobalManager.Instance.roommates[GlobalManager.Instance.Invitation - 1].RelationShip += (s.action.Consume * 2); } } } s.SetActionName(""); s.action = null; EventCenter.Broadcast(EventType.UpdateActionCaption, "", ""); } } }