示例#1
0
 public PlayerRole(string RoleName, string RoleDescription, PowerFlags RolePowers, int[] PowerCharges, PlayerAlignment RoleAlignment)
 {
     Name        = RoleName;
     Description = RoleDescription;
     Powers      = RolePowers;
     Charges     = PowerCharges;
     Alignment   = RoleAlignment;
 }
    void Awake()
    {
        if (instance == null)
        {
            instance = this;
            DontDestroyOnLoad(instance);
        }
        else
        {
            Destroy(gameObject);
        }

        powerButton = GameObject.FindGameObjectWithTag("PBUI").GetComponent <Image>();

        PlayerAttackPower   = 25;
        powerButton.enabled = false;
    }
示例#3
0
 internal IReadOnlyList <ServerAction> GetPlayerAlignmentActions(PlayerAlignment alignment)
 {
     return(alignmentActions.FirstOrDefault(x => x.Alignment == alignment).Actions.ToArray());
 }