コード例 #1
0
ファイル: OrgTeam.cs プロジェクト: clandowski/PF_Downtime
 /// <summary>
 /// Instantiates an OrgTeam object
 /// </summary>
 /// <param name="Name">User controlled name of Team</param>
 /// <param name="Team">BaseTeam object to determine statistics</param>
 /// <param name="Notes">User controlled notes</param>
 /// <param name="ActiveResource">Resource this room is currently generating</param>
 /// <param name="DaysComplete"></param>
 public OrgTeam(String Name, BaseTeam Team, String Notes, Models.BaseResource ActiveResource)
 {
     this.Name = Name;
     this.Team = Team;
     this.ActiveResource = ActiveResource;
     this.Notes = Notes;
 }
コード例 #2
0
 private void teamWon(BaseTeam team)
 {
     HSGame.Instance.SetRound(new ResultsRound()
     {
         WinningTeam = team,
         GameTime    = (int)this.TimeElapsed
     });
 }
コード例 #3
0
 public override void OnPlayerTeamChange(HSPlayer ply, BaseTeam team)
 {
     if (team.Players.Count != 0)
     {
         return;
     }
     HSGame.Instance.SetRound(new WaitingRound());
 }
コード例 #4
0
        public override void OnPlayerTeamChange(HSPlayer ply, BaseTeam team)
        {
            if (team.Players.Count != 0)
            {
                return;
            }
            BaseTeam winningTeam = (ply.Team is HiderTeam ? HSGame.Instance.Seekers : HSGame.Instance.Hiders);

            teamWon(winningTeam);
        }
コード例 #5
0
ファイル: UnitStore.cs プロジェクト: Bulletdrone/AllForOne
    /// <summary>
    /// Instantiates a unit with the selected attributes given in the buy menu.
    /// </summary>
    public void BuyUnit(Vector3 position, GameObject unit, int teamNumber, BaseTeam customer)
    {
        //Parameters Filled
        boughtUnitObject   = unit;
        boughtUnitPosition = position;
        this.teamNumber    = teamNumber;
        this.customer      = customer;

        //Texts
        unitPointAvailable          = customer.unitPoints;
        unitPointAvailableText.text = "Coins: " + unitPointAvailable;

        BuyMenu(true);
    }
コード例 #6
0
    /// <summary>
    /// Places a unit on the map.
    /// </summary>
    public void CreateUnit(int speed, int strength, int defense, int teamNumber, List <Feature> features, Weapon weapon, BaseTeam team)
    {
        this.speed    = speed;
        this.strength = strength;
        this.defense  = defense;

        this.teamNumber = teamNumber;
        this.weapon     = weapon;

        this.team = team;

        CheckSpecialFeatures(features);
        unitInterface.SetSlider(hitPoints);

        cameraOrigionalPosition = cameraTransform.localPosition;
        this.speed = speed * 10;
    }
コード例 #7
0
        public override void Tick()
        {
            base.Tick();

            BaseRound currRound = HSGame.Instance.CurrentRound;

            if (currRound is null)
            {
                return;
            }

            roundName.Text = currRound.RoundText;

            BaseTeam currTeam = (Local.Pawn as HSPlayer).Team;

            teamPanel.SetClass("hidden", currTeam is null);

            if (currTeam is not null)
            {
                teamName.Text            = currTeam.TeamName;
                teamName.Style.FontColor = currTeam.TeamColor;
                teamName.Style.Dirty();
            }
        }
コード例 #8
0
 public virtual void OnPlayerTeamChange(HSPlayer ply, BaseTeam team)
 {
 }