예제 #1
0
 public void AddProtectionOfPlayer(ProtectionOfPlayer protectionOfPlayer)
 {
     if (player != null)
     {
         protectionOfPlayer.PlayerId = player.Id;
         protectionOfPlayerRepository.AddProtectionOfPlayer(protectionOfPlayer);
         CheckAchivements();
     }
 }
예제 #2
0
        public void NotifyProtectionEquipped(ObjectContainedInventory objectContainedInventory)
        {
            Item itemOfProtection = objectContainedInventory.GetItem();
            ProtectionOfPlayer protectionOfPlayer = new ProtectionOfPlayer
            {
                LevelProtection = itemOfProtection.Level,
                TypeProtection  = itemOfProtection.Type.ToString()
            };

            if (ProtectionEquipped != null)
            {
                ProtectionEquipped(protectionOfPlayer);
            }
        }
예제 #3
0
 private void OnProtectionEquipped(ProtectionOfPlayer protectionOfPlayer)
 {
     achivementController.AddProtectionOfPlayer(protectionOfPlayer);
 }
예제 #4
0
 public virtual void AddProtectionOfPlayer(ProtectionOfPlayer protectionOfPlayer)
 {
     repository.AddProtectionOfPlayer(protectionOfPlayer);
 }