<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: Client_Game_Packet.proto

namespace Game\Protobuf;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\RepeatedField;
use Google\Protobuf\Internal\GPBUtil;

/**
 *引导匹配返回
 *
 * Generated from protobuf message <code>Game.Protobuf.GCGuideMatching</code>
 */
class GCGuideMatching extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>string ip = 1;</code>
     */
    protected $ip = '';
    /**
     * Generated from protobuf field <code>int32 port = 2;</code>
     */
    protected $port = 0;
    /**
     * Generated from protobuf field <code>repeated .Game.Protobuf.PlayerInfo PInfo = 3;</code>
     */
    private $PInfo;
    /**
     *场景id
     *
     * Generated from protobuf field <code>int32 SceneId = 4;</code>
     */
    protected $SceneId = 0;
    /**
     * Generated from protobuf field <code>uint64 JoinId = 5;</code>
     */
    protected $JoinId = 0;
    /**
     *AI信息
     *
     * Generated from protobuf field <code>repeated .Game.Protobuf.AIInfo AInfo = 6;</code>
     */
    private $AInfo;
    /**
     *比赛类型
     *
     * Generated from protobuf field <code>int32 MatchType = 7;</code>
     */
    protected $MatchType = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $ip
     *     @type int $port
     *     @type \Game\Protobuf\PlayerInfo[]|\Google\Protobuf\Internal\RepeatedField $PInfo
     *     @type int $SceneId
     *          场景id
     *     @type int|string $JoinId
     *     @type \Game\Protobuf\AIInfo[]|\Google\Protobuf\Internal\RepeatedField $AInfo
     *          AI信息
     *     @type int $MatchType
     *          比赛类型
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\ClientGamePacket::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>string ip = 1;</code>
     * @return string
     */
    public function getIp()
    {
        return $this->ip;
    }

    /**
     * Generated from protobuf field <code>string ip = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setIp($var)
    {
        GPBUtil::checkString($var, True);
        $this->ip = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>int32 port = 2;</code>
     * @return int
     */
    public function getPort()
    {
        return $this->port;
    }

    /**
     * Generated from protobuf field <code>int32 port = 2;</code>
     * @param int $var
     * @return $this
     */
    public function setPort($var)
    {
        GPBUtil::checkInt32($var);
        $this->port = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>repeated .Game.Protobuf.PlayerInfo PInfo = 3;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getPInfo()
    {
        return $this->PInfo;
    }

    /**
     * Generated from protobuf field <code>repeated .Game.Protobuf.PlayerInfo PInfo = 3;</code>
     * @param \Game\Protobuf\PlayerInfo[]|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setPInfo($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Game\Protobuf\PlayerInfo::class);
        $this->PInfo = $arr;

        return $this;
    }

    /**
     *场景id
     *
     * Generated from protobuf field <code>int32 SceneId = 4;</code>
     * @return int
     */
    public function getSceneId()
    {
        return $this->SceneId;
    }

    /**
     *场景id
     *
     * Generated from protobuf field <code>int32 SceneId = 4;</code>
     * @param int $var
     * @return $this
     */
    public function setSceneId($var)
    {
        GPBUtil::checkInt32($var);
        $this->SceneId = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>uint64 JoinId = 5;</code>
     * @return int|string
     */
    public function getJoinId()
    {
        return $this->JoinId;
    }

    /**
     * Generated from protobuf field <code>uint64 JoinId = 5;</code>
     * @param int|string $var
     * @return $this
     */
    public function setJoinId($var)
    {
        GPBUtil::checkUint64($var);
        $this->JoinId = $var;

        return $this;
    }

    /**
     *AI信息
     *
     * Generated from protobuf field <code>repeated .Game.Protobuf.AIInfo AInfo = 6;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getAInfo()
    {
        return $this->AInfo;
    }

    /**
     *AI信息
     *
     * Generated from protobuf field <code>repeated .Game.Protobuf.AIInfo AInfo = 6;</code>
     * @param \Game\Protobuf\AIInfo[]|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setAInfo($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Game\Protobuf\AIInfo::class);
        $this->AInfo = $arr;

        return $this;
    }

    /**
     *比赛类型
     *
     * Generated from protobuf field <code>int32 MatchType = 7;</code>
     * @return int
     */
    public function getMatchType()
    {
        return $this->MatchType;
    }

    /**
     *比赛类型
     *
     * Generated from protobuf field <code>int32 MatchType = 7;</code>
     * @param int $var
     * @return $this
     */
    public function setMatchType($var)
    {
        GPBUtil::checkInt32($var);
        $this->MatchType = $var;

        return $this;
    }

}

