示例#1
0
        /// <summary>
        /// 分配一个对象
        /// </summary>
        /// <param name="value">初始值</param>
        /// <returns></returns>
        public static VarByte Alloc(byte value)
        {
            VarByte var = Alloc();

            var.Value = value;
            return(var);
        }
示例#2
0
        /// <summary>
        /// 分配一个对象
        /// </summary>
        /// <returns></returns>
        public static VarByte Alloc()
        {
            VarByte var = GameEntry.Pool.DequeueVarObject <VarByte>();

            var.Value = 0;
            var.Retain();
            return(var);
        }