Player.cs 899 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading.Tasks;
  6. namespace YJMPD_UWP.Model.Object
  7. {
  8. public class Player
  9. {
  10. public string Username { get; private set; }
  11. public double PointsTotal { get; private set; }
  12. public double Points { get; private set; }
  13. public Player(string username)
  14. {
  15. Username = username;
  16. Points = 0;
  17. PointsTotal = 0;
  18. }
  19. public Player(string username, double pointstotal)
  20. {
  21. Username = username;
  22. PointsTotal = pointstotal;
  23. Points = 0;
  24. }
  25. public void Reset()
  26. {
  27. Points = 0;
  28. }
  29. public void Update(double pointstotal, double points)
  30. {
  31. PointsTotal = pointstotal;
  32. Points = points;
  33. }
  34. }
  35. }