Exemplo n.º 1
0
        public override void OnButtonClick(int buttonID)
        {
            switch ((Buttons)buttonID)
            {
            case Buttons.Add:
                PartySystem.TriggerAddPartyMember();

                break;

            case Buttons.Leave:
                PartySystem.LeaveParty();

                break;

            case Buttons.Loot:
                PartySystem.AllowPartyLoot = !PartySystem.AllowPartyLoot ? true : false;

                break;

            case Buttons.Message:

                //
                break;
            }
        }
    public void CmdPartyPromote(int index)
    {
        string[] members = party.members;

        for (int k = 1; k < members.Length; k++)
        {
            PartySystem.KickFromParty(party.partyId, name, members[k]);
        }

        PartySystem.LeaveParty(party.partyId, name);
        PartySystem.FormParty(members[index], name);

        Player invitor = onlinePlayers[members[index]];

        for (int a = 1; a < members.Length; a++)
        {
            if (a != index)
            {
                PartySystem.AddToParty(invitor.party.partyId, members[a]);
            }
        }
    }
Exemplo n.º 3
0
 // version without cmd because we need to call it from the server too
 public void Leave()
 {
     // try to leave. party system will do all the validation.
     PartySystem.LeaveParty(party.partyId, name);
 }