public void Attack() { if (player1) { player.PerformMeleeAttack(target, weapon); } else { target.PerformMeleeAttack(player, weapon); } player1 = !player1; MyLevels.RefreshResourceBar(); TargetLevels.RefreshResourceBar(); //MyLevels.Unit = player; //TargetLevels.Unit = target; }
private void Attack_Click(object sender, RoutedEventArgs e) { Navigation.AddAndDropSpheres(); //scene1.DropCharacterSpheres(); if (player1) { player.PerformMeleeAttack(target, weapon); } else { target.PerformMeleeAttack(player, weapon); } player1 = !player1; MyLevels.RefreshResourceBar(); TargetLevels.RefreshResourceBar(); //MyLevels.BasicUnit = player; //TargetLevels.BasicUnit = target; }