File tree 2 files changed +23
-3
lines changed
2 files changed +23
-3
lines changed Original file line number Diff line number Diff line change 1
1
# EnumBitSet
2
2
A memory efficient ` ISet ` for enums that store data using bit masks for C#.
3
3
4
- Currently, there is an implementation using ` int ` as data (` EnumBitSet32<T> ` ),
5
- supporting enums with up to 32 values.
4
+ Current implementations:
5
+ - ` EnumBitSet32<T> ` : uses ` int ` as data, supporting enums with up to 32 values.
6
+ - ` EnumBitSet64<T> ` : uses ` long ` as data, supporting enums with up to 64 values.
6
7
7
- In Unity, there's a custom property drawer for selecting the containing enums.
8
+ ## Unity Property Drawer
9
+ In Unity, there's a custom property drawer for selecting the containing enums:
10
+
11
+ ``` cs
12
+ using EnumBitSet ;
13
+ using UnityEngine ;
14
+
15
+ public class ScriptWithEnumSet : MonoBehaviour
16
+ {
17
+ public enum TestEnum
18
+ {
19
+ Zero , One , Two , Three
20
+ }
21
+
22
+ public EnumBitSet32 <TestEnum > aBitset ;
23
+ public EnumBitSet64 <TestEnum > anotherBitset ;
24
+ }
25
+ ```
26
+
27
+ ![ ] ( Extras~/CustomDrawer.png )
You can’t perform that action at this time.
0 commit comments