yyl
12 小时以前 5d3366f2e0f687995eb7ad2107c4379fe7acd4e8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
//--------------------------------------------------------
//    [Author]:           玩个游戏
//    [  Date ]:           Monday, July 31, 2017
//--------------------------------------------------------
using UnityEngine;
using System.Collections;
 
 
    public struct Item
    {
        public int id;
        public int count;       //兼容旧代码保留
        public ulong countEx;   //兼容旧代码count,当数量超过了32位无法表示时使用
        public int quality;
        public int bind;
 
        public Item(int _id, ulong _count)
        {
            this.id = _id;
            this.count = (int)_count;
            this.quality = 0;
            this.bind = 0;
            this.countEx = _count;
        }
 
        public Item(int _id, ulong _count, int _quality)
        {
            this.id = _id;
            this.count = (int)_count;
            this.quality = _quality;
            this.bind = 0;
            this.countEx = _count;
        }
 
        public Item(int _id, ulong _count, int _bind = 0, int _quality = 0)
        {
            this.id = _id;
            this.count = (int)_count;
            this.quality = _quality;
            this.bind = _bind;
            this.countEx = _count;
        }
 
        #region 旧代码兼容 显示无法超过32位
 
        public Item(int _id, int _count)
        {
            this.id = _id;
            this.count = _count;
            this.quality = 0;
            this.bind = 0;
            this.countEx = (ulong)_count;
        }
 
        public Item(int _id, int _count, int _quality)
        {
            this.id = _id;
            this.count = _count;
            this.quality = _quality;
            this.bind = 0;
            this.countEx = (ulong)_count;
        }
 
 
        public Item(int _id, int _count, int _bind = 0, int _quality = 0)
        {
            this.id = _id;
            this.count = _count;
            this.quality = _quality;
            this.bind = _bind;
            this.countEx = (ulong)_count;
        }
        #endregion
    }