Advertisement
Guest User

Untitled

a guest
Jul 29th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.79 KB | None | 0 0
  1.  
  2. using UnityEngine;
  3. using System.Collections;
  4. using GameFramework.Patterns;
  5.  
  6. // Some Ideas of what need to be in here, though this may be temporary
  7. public struct PlayerDataCore
  8. {
  9. private string userName;
  10. public string UserName { get {return userName;} set {userName = value;} }
  11.  
  12. private string password;
  13. public string Password { get {return password;} set {password = value;} }
  14.  
  15. private string clanName;
  16. public string ClanName { get {return clanName;} set {clanName = value;} }
  17.  
  18. private int totalClanSlotCount;
  19. public int TotalClanSlotCount { get {return totalClanSlotCount;} set {totalClanSlotCount = value;} }
  20.  
  21. private int availableClanSlots;
  22. public int AvailableClanSlots { get {return availableClanSlots;} set {availableClanSlots = value;} }
  23. }
  24.  
  25.  
  26. public class PlayerCore
  27. {
  28. public static PlayerCore Instance { get { return Singleton<PlayerCore>.Instance; } }
  29.  
  30. private int touched;
  31. public int Touched { get {return touched;} }
  32.  
  33. private bool connectedToChat = false;
  34. public bool ConnectedToChat { get {return connectedToChat;} }
  35.  
  36.  
  37.  
  38.  
  39. public PlayerCore()
  40. {
  41. PlayerDataCore playerDataCore = new PlayerDataCore();
  42. playerDataCore.UserName = "FUCK";
  43. Debug.Log("Player Core has been instanced...");
  44. touched = 0;
  45. try
  46. {
  47. //Debug.Log("Trying from PlayerCore......");
  48. Debug.Log(string.Format("UserName: {0}", playerDataCore.UserName));
  49. }
  50. finally
  51. {
  52. //Debug.Log("Finally from PlayerCore......");
  53. }
  54. }
  55.  
  56. public void addTouched(int val)
  57. {
  58. touched += val;
  59. }
  60.  
  61. public void CheckConnectedToChat()
  62. {
  63. if(connectedToChat == true)
  64. {
  65. Debug.Log("Connected to Chat...");
  66. }
  67. else
  68. {
  69. Debug.Log("NOT Connected to Chat...");
  70. }
  71. }
  72.  
  73. public void SetConnectedToChat(bool value)
  74. {
  75. connectedToChat = value;
  76. }
  77. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement