Advertisement
gmansano

Atividade 6 - Exercício 3 [Guerreiro.cs]

Sep 30th, 2020
551
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.24 KB | None | 0 0
  1. using System;
  2.  
  3. namespace Atividade6Ex3
  4. {
  5.     public abstract class Guerreiro : Heroi
  6.     {
  7.         protected int energia;
  8.        
  9.         public int energia_p
  10.         {
  11.             get { return energia; }
  12.             set { if (value >= 0) energia = value; }
  13.         }
  14.     }
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement