summaryrefslogtreecommitdiff
path: root/Library/Artifacts/46/4640a53485715a0aefb63f7dbf75aa3b
blob: 2311b4a7f1d12b8dfcb88ba3784290dd451d1912 (plain)
ofshex dumpascii
0000 00 00 0f 81 00 00 be 4c 00 00 00 15 00 00 10 00 00 00 00 00 32 30 31 39 2e 33 2e 36 66 31 00 fe .......L............2019.3.6f1..
0020 ff ff ff 01 02 00 00 00 0b 04 00 00 00 ff ff 66 9a 86 21 eb 14 35 98 39 dd 34 1d 51 0e c1 f3 42 ...............f..!..5.9.4.Q...B
0040 00 00 00 ed 00 00 00 02 00 00 00 00 00 00 00 37 00 00 80 ff ff ff ff 00 00 00 00 00 80 00 00 00 ...............7................
0060 00 00 00 00 00 00 00 01 00 01 00 a6 03 00 80 b2 01 00 80 04 00 00 00 01 00 00 00 01 00 00 00 00 ................................
0080 00 00 00 00 00 00 00 01 00 01 00 0d 00 00 00 45 04 00 80 0c 00 00 00 02 00 00 00 01 00 00 00 00 ...............E................
00a0 00 00 00 00 00 00 00 01 00 02 00 de 00 00 80 23 00 00 00 04 00 00 00 03 00 00 00 01 00 80 00 00 ...............#................
00c0 00 00 00 00 00 00 00 01 00 02 00 2e 03 00 80 2c 00 00 00 08 00 00 00 04 00 00 00 01 00 80 00 00 ...............,................
00e0 00 00 00 00 00 00 00 01 00 01 00 35 00 00 00 61 04 00 80 0c 00 00 00 05 00 00 00 01 00 00 00 00 ...........5...a................
0100 00 00 00 00 00 00 00 01 00 02 00 de 00 00 80 23 00 00 00 04 00 00 00 06 00 00 00 01 00 80 00 00 ...............#................
0120 00 00 00 00 00 00 00 01 00 02 00 2e 03 00 80 2c 00 00 00 08 00 00 00 07 00 00 00 01 00 80 00 00 ...............,................
0140 00 00 00 00 00 00 00 01 00 01 00 86 02 00 80 72 04 00 80 0c 00 00 00 08 00 00 00 01 00 00 00 00 ...............r................
0160 00 00 00 00 00 00 00 01 00 02 00 de 00 00 80 23 00 00 00 04 00 00 00 09 00 00 00 01 00 80 00 00 ...............#................
0180 00 00 00 00 00 00 00 01 00 02 00 2e 03 00 80 2c 00 00 00 08 00 00 00 0a 00 00 00 01 00 80 00 00 ...............,................
01a0 00 00 00 00 00 00 00 01 00 01 00 48 03 00 80 ab 01 00 80 ff ff ff ff 0b 00 00 00 01 80 08 00 00 ...........H....................
01c0 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 00 00 80 ff ff ff ff 0c 00 00 00 01 40 08 00 00 ...........1...1............@...
01e0 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b 03 00 80 04 00 00 00 0d 00 00 00 01 00 08 00 00 ................................
0200 00 00 00 00 00 00 00 01 00 03 00 51 00 00 80 6a 00 00 80 01 00 00 00 0e 00 00 00 01 00 08 00 00 ...........Q...j................
0220 00 00 00 00 00 00 00 01 00 01 00 f1 00 00 80 4a 00 00 00 ff ff ff ff 0f 00 00 00 00 c0 00 00 00 ...............J................
0240 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 00 00 80 ff ff ff ff 10 00 00 00 00 80 00 00 00 ...........1...1................
0260 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b 03 00 80 04 00 00 00 11 00 00 00 00 00 00 00 00 ................................
0280 00 00 00 00 00 00 00 01 00 03 00 1f 02 00 80 6a 00 00 80 ff ff ff ff 12 00 00 00 00 80 00 00 00 ...............j................
02a0 00 00 00 00 00 00 00 01 00 04 00 5c 00 00 00 9b 00 00 80 ff ff ff ff 13 00 00 00 00 80 00 00 00 ...........\....................
02c0 00 00 00 00 00 00 00 01 00 05 00 48 03 00 80 72 00 00 00 ff ff ff ff 14 00 00 00 00 80 00 00 00 ...........H...r................
02e0 00 00 00 00 00 00 00 01 00 06 01 31 00 00 80 31 00 00 80 ff ff ff ff 15 00 00 00 01 40 00 00 00 ...........1...1............@...
0300 00 00 00 00 00 00 00 01 00 07 00 de 00 00 80 1b 03 00 80 04 00 00 00 16 00 00 00 01 00 00 00 00 ................................
0320 00 00 00 00 00 00 00 01 00 07 00 51 00 00 80 6a 00 00 80 01 00 00 00 17 00 00 00 01 00 00 00 00 ...........Q...j................
0340 00 00 00 00 00 00 00 01 00 05 00 48 03 00 80 77 00 00 00 ff ff ff ff 18 00 00 00 00 80 00 00 00 ...........H...w................
0360 00 00 00 00 00 00 00 01 00 06 01 31 00 00 80 31 00 00 80 ff ff ff ff 19 00 00 00 01 40 00 00 00 ...........1...1............@...
0380 00 00 00 00 00 00 00 01 00 07 00 de 00 00 80 1b 03 00 80 04 00 00 00 1a 00 00 00 01 00 00 00 00 ................................
03a0 00 00 00 00 00 00 00 01 00 07 00 51 00 00 80 6a 00 00 80 01 00 00 00 1b 00 00 00 01 00 00 00 00 ...........Q...j................
03c0 00 00 00 00 00 00 00 01 00 05 00 48 03 00 80 80 00 00 00 ff ff ff ff 1c 00 00 00 00 80 00 00 00 ...........H....................
03e0 00 00 00 00 00 00 00 01 00 06 01 31 00 00 80 31 00 00 80 ff ff ff ff 1d 00 00 00 01 40 00 00 00 ...........1...1............@...
0400 00 00 00 00 00 00 00 01 00 07 00 de 00 00 80 1b 03 00 80 04 00 00 00 1e 00 00 00 01 00 00 00 00 ................................
0420 00 00 00 00 00 00 00 01 00 07 00 51 00 00 80 6a 00 00 80 01 00 00 00 1f 00 00 00 01 00 00 00 00 ...........Q...j................
0440 00 00 00 00 00 00 00 01 00 04 00 79 02 00 80 0a 03 00 80 0c 00 00 00 20 00 00 00 00 00 00 00 00 ...........y....................
0460 00 00 00 00 00 00 00 01 00 05 00 de 00 00 80 23 00 00 00 04 00 00 00 21 00 00 00 01 00 80 00 00 ...............#.......!........
0480 00 00 00 00 00 00 00 01 00 05 00 2e 03 00 80 2c 00 00 00 08 00 00 00 22 00 00 00 01 00 80 00 00 ...............,......."........
04a0 00 00 00 00 00 00 00 01 00 01 00 11 03 00 80 85 00 00 00 ff ff ff ff 23 00 00 00 01 40 08 00 00 .......................#....@...
04c0 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 00 00 80 ff ff ff ff 24 00 00 00 01 00 08 00 00 ...........1...1.......$........
04e0 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b 03 00 80 04 00 00 00 25 00 00 00 01 00 08 00 00 .......................%........
0500 00 00 00 00 00 00 00 01 00 03 00 2e 03 00 80 6a 00 00 80 08 00 00 00 26 00 00 00 01 00 08 00 00 ...............j.......&........
0520 00 00 00 00 00 00 00 01 00 01 00 d5 03 00 80 93 00 00 00 ff ff ff ff 27 00 00 00 00 80 00 00 00 .......................'........
0540 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 00 00 80 ff ff ff ff 28 00 00 00 00 c0 00 00 00 ...........1...1.......(........
0560 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b 03 00 80 04 00 00 00 29 00 00 00 00 00 00 00 00 .......................)........
0580 00 00 00 00 00 00 00 01 00 03 00 1f 02 00 80 6a 00 00 80 ff ff ff ff 2a 00 00 00 00 80 00 00 00 ...............j.......*........
05a0 00 00 00 00 00 00 00 01 00 04 00 48 03 00 80 9b 00 00 80 ff ff ff ff 2b 00 00 00 00 80 00 00 00 ...........H...........+........
05c0 00 00 00 00 00 00 00 01 00 05 01 31 00 00 80 31 00 00 80 ff ff ff ff 2c 00 00 00 01 40 00 00 00 ...........1...1.......,....@...
05e0 00 00 00 00 00 00 00 01 00 06 00 de 00 00 80 1b 03 00 80 04 00 00 00 2d 00 00 00 01 00 00 00 00 .......................-........
0600 00 00 00 00 00 00 00 01 00 06 00 51 00 00 80 6a 00 00 80 01 00 00 00 2e 00 00 00 01 00 00 00 00 ...........Q...j................
0620 00 00 00 00 00 00 00 01 00 04 00 79 02 00 80 0a 03 00 80 0c 00 00 00 2f 00 00 00 00 00 00 00 00 ...........y.........../........
0640 00 00 00 00 00 00 00 01 00 05 00 de 00 00 80 23 00 00 00 04 00 00 00 30 00 00 00 01 00 80 00 00 ...............#.......0........
0660 00 00 00 00 00 00 00 01 00 05 00 2e 03 00 80 2c 00 00 00 08 00 00 00 31 00 00 00 01 00 80 00 00 ...............,.......1........
0680 00 00 00 00 00 00 00 01 00 01 00 20 03 00 80 a7 00 00 00 02 00 00 00 32 00 00 00 00 40 00 00 00 .......................2....@...
06a0 00 00 00 00 00 00 00 01 00 01 00 be 02 00 80 b6 00 00 00 0c 00 00 00 33 00 00 00 00 40 00 00 00 .......................3....@...
06c0 00 00 00 00 00 00 00 01 00 02 00 de 00 00 80 23 00 00 00 04 00 00 00 34 00 00 00 01 00 80 00 00 ...............#.......4........
06e0 00 00 00 00 00 00 00 01 00 02 00 2e 03 00 80 2c 00 00 00 08 00 00 00 35 00 00 00 01 00 80 00 00 ...............,.......5........
0700 00 00 00 00 00 00 00 01 00 01 00 48 03 00 80 bb 00 00 00 ff ff ff ff 36 00 00 00 01 80 00 00 00 ...........H...........6........
0720 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 00 00 80 ff ff ff ff 37 00 00 00 01 40 00 00 00 ...........1...1.......7....@...
0740 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b 03 00 80 04 00 00 00 38 00 00 00 01 00 00 00 00 .......................8........
0760 00 00 00 00 00 00 00 01 00 03 00 51 00 00 80 6a 00 00 80 01 00 00 00 39 00 00 00 01 00 00 00 00 ...........Q...j.......9........
0780 00 00 00 00 00 00 00 01 00 01 00 48 03 00 80 c6 00 00 00 ff ff ff ff 3a 00 00 00 01 80 00 00 00 ...........H...........:........
07a0 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 00 00 80 ff ff ff ff 3b 00 00 00 01 40 00 00 00 ...........1...1.......;....@...
07c0 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b 03 00 80 04 00 00 00 3c 00 00 00 01 00 00 00 00 .......................<........
07e0 00 00 00 00 00 00 00 01 00 03 00 51 00 00 80 6a 00 00 80 01 00 00 00 3d 00 00 00 01 00 00 00 00 ...........Q...j.......=........
0800 00 00 00 00 00 00 00 01 00 01 00 48 03 00 80 d8 00 00 00 ff ff ff ff 3e 00 00 00 01 80 00 00 00 ...........H...........>........
0820 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 00 00 80 ff ff ff ff 3f 00 00 00 01 40 00 00 00 ...........1...1.......?....@...
0840 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b 03 00 80 04 00 00 00 40 00 00 00 01 00 00 00 00 .......................@........
0860 00 00 00 00 00 00 00 01 00 03 00 51 00 00 80 6a 00 00 80 01 00 00 00 41 00 00 00 01 00 00 00 00 ...........Q...j.......A........
0880 00 00 00 00 00 00 00 4d 6f 6e 6f 49 6d 70 6f 72 74 65 72 00 50 50 74 72 3c 45 64 69 74 6f 72 45 .......MonoImporter.PPtr<EditorE
08a0 78 74 65 6e 73 69 6f 6e 3e 00 6d 5f 46 69 6c 65 49 44 00 6d 5f 50 61 74 68 49 44 00 50 50 74 72 xtension>.m_FileID.m_PathID.PPtr
08c0 3c 50 72 65 66 61 62 49 6e 73 74 61 6e 63 65 3e 00 6d 5f 45 78 74 65 72 6e 61 6c 4f 62 6a 65 63 <PrefabInstance>.m_ExternalObjec
08e0 74 73 00 53 6f 75 72 63 65 41 73 73 65 74 49 64 65 6e 74 69 66 69 65 72 00 74 79 70 65 00 61 73 ts.SourceAssetIdentifier.type.as
0900 73 65 6d 62 6c 79 00 6e 61 6d 65 00 6d 5f 55 73 65 64 46 69 6c 65 49 44 73 00 6d 5f 44 65 66 61 sembly.name.m_UsedFileIDs.m_Defa
0920 75 6c 74 52 65 66 65 72 65 6e 63 65 73 00 65 78 65 63 75 74 69 6f 6e 4f 72 64 65 72 00 69 63 6f ultReferences.executionOrder.ico
0940 6e 00 6d 5f 55 73 65 72 44 61 74 61 00 6d 5f 41 73 73 65 74 42 75 6e 64 6c 65 4e 61 6d 65 00 6d n.m_UserData.m_AssetBundleName.m
0960 5f 41 73 73 65 74 42 75 6e 64 6c 65 56 61 72 69 61 6e 74 00 00 00 00 00 73 00 00 00 00 ff ff a3 _AssetBundleVariant.....s.......
0980 47 f1 d7 dc 8f 5a 35 36 a0 3a 21 40 69 c1 4a 2a 00 00 00 81 00 00 00 05 00 00 00 15 01 00 80 37 G....Z56.:!@i.J*...............7
09a0 00 00 80 ff ff ff ff 00 00 00 00 00 80 00 00 00 00 00 00 00 00 00 00 01 00 01 00 a6 03 00 80 b2 ................................
09c0 01 00 80 04 00 00 00 01 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 01 00 00 00 00 00 45 ...............................E
09e0 04 00 80 0c 00 00 00 02 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 02 00 de 00 00 80 16 ................................
0a00 00 00 00 04 00 00 00 03 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 02 00 2e 03 00 80 1f ................................
0a20 00 00 00 08 00 00 00 04 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 01 00 28 00 00 00 61 ...........................(...a
0a40 04 00 80 0c 00 00 00 05 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 02 00 de 00 00 80 16 ................................
0a60 00 00 00 04 00 00 00 06 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 02 00 2e 03 00 80 1f ................................
0a80 00 00 00 08 00 00 00 07 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 01 00 86 02 00 80 72 ...............................r
0aa0 04 00 80 0c 00 00 00 08 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 02 00 de 00 00 80 16 ................................
0ac0 00 00 00 04 00 00 00 09 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 02 00 2e 03 00 80 1f ................................
0ae0 00 00 00 08 00 00 00 0a 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 01 00 48 03 00 80 ab ...........................H....
0b00 01 00 80 ff ff ff ff 0b 00 00 00 01 80 08 00 00 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 ...........................1...1
0b20 00 00 80 ff ff ff ff 0c 00 00 00 01 40 08 00 00 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b ............@...................
0b40 03 00 80 04 00 00 00 0d 00 00 00 01 00 08 00 00 00 00 00 00 00 00 00 01 00 03 00 51 00 00 80 6a ...........................Q...j
0b60 00 00 80 01 00 00 00 0e 00 00 00 01 00 08 00 00 00 00 00 00 00 00 00 01 00 01 00 48 03 00 80 ea ...........................H....
0b80 01 00 80 ff ff ff ff 0f 00 00 00 01 80 00 00 00 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 ...........................1...1
0ba0 00 00 80 ff ff ff ff 10 00 00 00 01 40 00 00 00 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b ............@...................
0bc0 03 00 80 04 00 00 00 11 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 03 00 51 00 00 80 6a ...........................Q...j
0be0 00 00 80 01 00 00 00 12 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 01 00 f1 00 00 80 3d ...............................=
0c00 00 00 00 ff ff ff ff 13 00 00 00 01 80 00 00 00 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 ...........................1...1
0c20 00 00 80 ff ff ff ff 14 00 00 00 01 80 00 00 00 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b ................................
0c40 03 00 80 04 00 00 00 15 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 03 00 1f 02 00 80 6a ...............................j
0c60 00 00 80 ff ff ff ff 16 00 00 00 01 80 00 00 00 00 00 00 00 00 00 00 01 00 04 00 48 03 00 80 9b ...........................H....
0c80 00 00 80 ff ff ff ff 17 00 00 00 01 80 00 00 00 00 00 00 00 00 00 00 01 00 05 01 31 00 00 80 31 ...........................1...1
0ca0 00 00 80 ff ff ff ff 18 00 00 00 01 40 00 00 00 00 00 00 00 00 00 00 01 00 06 00 de 00 00 80 1b ............@...................
0cc0 03 00 80 04 00 00 00 19 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 06 00 51 00 00 80 6a ...........................Q...j
0ce0 00 00 80 01 00 00 00 1a 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 04 00 79 02 00 80 0a ...........................y....
0d00 03 00 80 0c 00 00 00 1b 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 01 00 05 00 de 00 00 80 16 ................................
0d20 00 00 00 04 00 00 00 1c 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 05 00 2e 03 00 80 1f ................................
0d40 00 00 00 08 00 00 00 1d 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 01 00 79 02 00 80 51 ...........................y...Q
0d60 00 00 00 0c 00 00 00 1e 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 02 00 de 00 00 80 16 ................................
0d80 00 00 00 04 00 00 00 1f 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 02 00 2e 03 00 80 1f ................................
0da0 00 00 00 08 00 00 00 20 00 00 00 01 00 80 00 00 00 00 00 00 00 00 00 01 00 01 00 de 00 00 80 58 ...............................X
0dc0 00 00 00 04 00 00 00 21 00 00 00 10 00 00 00 00 00 00 00 00 00 00 00 01 00 01 00 48 03 00 80 69 .......!...................H...i
0de0 00 00 00 ff ff ff ff 22 00 00 00 10 80 00 00 00 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 ......."...................1...1
0e00 00 00 80 ff ff ff ff 23 00 00 00 11 40 00 00 00 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b .......#....@...................
0e20 03 00 80 04 00 00 00 24 00 00 00 11 00 00 00 00 00 00 00 00 00 00 00 01 00 03 00 51 00 00 80 6a .......$...................Q...j
0e40 00 00 80 01 00 00 00 25 00 00 00 11 00 00 00 00 00 00 00 00 00 00 00 01 00 01 00 48 03 00 80 75 .......%...................H...u
0e60 00 00 00 ff ff ff ff 26 00 00 00 10 80 00 00 00 00 00 00 00 00 00 00 01 00 02 01 31 00 00 80 31 .......&...................1...1
0e80 00 00 80 ff ff ff ff 27 00 00 00 11 40 00 00 00 00 00 00 00 00 00 00 01 00 03 00 de 00 00 80 1b .......'....@...................
0ea0 03 00 80 04 00 00 00 28 00 00 00 11 00 00 00 00 00 00 00 00 00 00 00 01 00 03 00 51 00 00 80 6a .......(...................Q...j
0ec0 00 00 80 01 00 00 00 29 00 00 00 11 00 00 00 00 00 00 00 00 00 00 00 50 50 74 72 3c 45 64 69 74 .......)...............PPtr<Edit
0ee0 6f 72 45 78 74 65 6e 73 69 6f 6e 3e 00 6d 5f 46 69 6c 65 49 44 00 6d 5f 50 61 74 68 49 44 00 50 orExtension>.m_FileID.m_PathID.P
0f00 50 74 72 3c 50 72 65 66 61 62 49 6e 73 74 61 6e 63 65 3e 00 6d 5f 44 65 66 61 75 6c 74 52 65 66 Ptr<PrefabInstance>.m_DefaultRef
0f20 65 72 65 6e 63 65 73 00 6d 5f 49 63 6f 6e 00 6d 5f 45 78 65 63 75 74 69 6f 6e 4f 72 64 65 72 00 erences.m_Icon.m_ExecutionOrder.
0f40 6d 5f 43 6c 61 73 73 4e 61 6d 65 00 6d 5f 4e 61 6d 65 73 70 61 63 65 00 00 00 00 00 02 00 00 00 m_ClassName.m_Namespace.........
0f60 03 00 00 00 00 00 00 00 00 00 00 00 5c 00 00 00 00 00 00 00 e0 79 af 00 00 00 00 00 60 00 00 00 ............\........y......`...
0f80 ec ad 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................................
0fa0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................................
0fc0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................................
0fe0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................................
1000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................................
1020 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 e0 79 af 00 00 00 00 00 00 00 00 00 .....................y..........
1040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................................
1060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................................
1080 00 00 00 00 00 00 00 00 1a 00 00 00 49 6e 70 75 74 41 63 74 69 6f 6e 53 65 74 75 70 45 78 74 65 ............InputActionSetupExte
10a0 6e 73 69 6f 6e 73 00 00 4d ad 00 00 75 73 69 6e 67 20 53 79 73 74 65 6d 3b 0d 0a 75 73 69 6e 67 nsions..M...using.System;..using
10c0 20 55 6e 69 74 79 45 6e 67 69 6e 65 2e 49 6e 70 75 74 53 79 73 74 65 6d 2e 4c 61 79 6f 75 74 73 .UnityEngine.InputSystem.Layouts
10e0 3b 0d 0a 75 73 69 6e 67 20 55 6e 69 74 79 45 6e 67 69 6e 65 2e 49 6e 70 75 74 53 79 73 74 65 6d ;..using.UnityEngine.InputSystem
1100 2e 55 74 69 6c 69 74 69 65 73 3b 0d 0a 0d 0a 6e 61 6d 65 73 70 61 63 65 20 55 6e 69 74 79 45 6e .Utilities;....namespace.UnityEn
1120 67 69 6e 65 2e 49 6e 70 75 74 53 79 73 74 65 6d 0d 0a 7b 0d 0a 20 20 20 20 2f 2f 2f 20 3c 73 75 gine.InputSystem..{......///.<su
1140 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 2f 2f 2f 20 4d 65 74 68 6f 64 73 20 74 6f 20 63 68 61 6e 67 mmary>......///.Methods.to.chang
1160 65 20 74 68 65 20 73 65 74 75 70 20 6f 66 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 e.the.setup.of.<see.cref="InputA
1180 63 74 69 6f 6e 22 2f 3e 2c 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e ction"/>,.<see.cref="InputAction
11a0 4d 61 70 22 2f 3e 2c 0d 0a 20 20 20 20 2f 2f 2f 20 61 6e 64 20 3c 73 65 65 20 63 72 65 66 3d 22 Map"/>,......///.and.<see.cref="
11c0 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 22 2f 3e 20 6f 62 6a 65 63 74 73 2e 0d 0a 20 20 InputActionAsset"/>.objects.....
11e0 20 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 2f 2f 2f 20 3c 72 65 6d 61 72 ..///.</summary>......///.<remar
1200 6b 73 3e 0d 0a 20 20 20 20 2f 2f 2f 20 55 6e 6c 69 6b 65 20 74 68 65 20 6d 65 74 68 6f 64 73 20 ks>......///.Unlike.the.methods.
1220 69 6e 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 52 65 62 69 6e 64 69 in.<see.cref="InputActionRebindi
1240 6e 67 45 78 74 65 6e 73 69 6f 6e 73 22 2f 3e 2c 20 74 68 65 20 6d 65 74 68 6f 64 73 20 68 65 72 ngExtensions"/>,.the.methods.her
1260 65 20 61 72 65 0d 0a 20 20 20 20 2f 2f 2f 20 67 65 6e 65 72 61 6c 6c 79 20 64 65 73 74 72 75 63 e.are......///.generally.destruc
1280 74 69 76 65 2c 20 69 2e 65 2e 20 74 68 65 79 20 77 69 6c 6c 20 72 65 61 72 72 61 6e 67 65 20 74 tive,.i.e..they.will.rearrange.t
12a0 68 65 20 64 61 74 61 20 66 6f 72 20 61 63 74 69 6f 6e 73 2e 0d 0a 20 20 20 20 2f 2f 2f 20 3c 2f he.data.for.actions.......///.</
12c0 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 63 6c 61 73 remarks>......public.static.clas
12e0 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 53 65 74 75 70 45 78 74 65 6e 73 69 6f 6e 73 0d 0a 20 20 s.InputActionSetupExtensions....
1300 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 ..{..........///.<summary>......
1320 20 20 20 20 2f 2f 2f 20 43 72 65 61 74 65 20 61 6e 20 61 63 74 69 6f 6e 20 6d 61 70 20 77 69 74 ....///.Create.an.action.map.wit
1340 68 20 74 68 65 20 67 69 76 65 6e 20 6e 61 6d 65 20 61 6e 64 20 61 64 64 20 69 74 20 74 6f 20 74 h.the.given.name.and.add.it.to.t
1360 68 65 20 61 73 73 65 74 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 he.asset...........///.</summary
1380 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 61 73 73 65 >..........///.<param.name="asse
13a0 74 22 3e 41 73 73 65 74 20 74 6f 20 61 64 64 20 74 68 65 20 61 63 74 69 6f 6e 20 6d 61 70 20 74 t">Asset.to.add.the.action.map.t
13c0 6f 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 o</param>..........///.<param.na
13e0 6d 65 3d 22 6e 61 6d 65 22 3e 4e 61 6d 65 20 74 6f 20 61 73 73 69 67 6e 20 74 6f 20 74 68 65 20 me="name">Name.to.assign.to.the.
1400 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 72 65 74 75 72 6e 73 3e 54 </param>..........///.<returns>T
1420 68 65 20 6e 65 77 6c 79 20 61 64 64 65 64 20 61 63 74 69 6f 6e 20 6d 61 70 2e 3c 2f 72 65 74 75 he.newly.added.action.map.</retu
1440 72 6e 73 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 rns>..........///.<exception.cre
1460 66 3d 22 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d f="ArgumentNullException"><param
1480 72 65 66 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 2f 3e 20 69 73 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 ref.name="asset"/>.is.<c>null</c
14a0 3e 20 6f 72 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 >.or..........///.<exception.cre
14c0 66 3d 22 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 22 3e 41 6e f="InvalidOperationException">An
14e0 20 61 63 74 69 6f 6e 20 6d 61 70 20 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 3c 70 61 72 61 .action.map.with.the.given.<para
1500 6d 72 65 66 20 6e 61 6d 65 3d 22 6e 61 6d 65 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 mref.name="name"/>..........///.
1520 61 6c 72 65 61 64 79 20 65 78 69 73 74 73 20 69 6e 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 already.exists.in.<paramref.name
1540 3d 22 61 73 73 65 74 22 2f 3e 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 ="asset"/>.</exception>.........
1560 20 2f 2f 2f 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6e 61 6d 65 22 2f 3e 20 69 73 20 .///.<paramref.name="name"/>.is.
1580 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 20 6f 72 20 65 6d 70 74 79 2e 3c 2f 65 78 63 65 70 74 69 6f 6e <c>null</c>.or.empty.</exception
15a0 3e 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 49 6e 70 75 74 41 63 >..........public.static.InputAc
15c0 74 69 6f 6e 4d 61 70 20 41 64 64 41 63 74 69 6f 6e 4d 61 70 28 74 68 69 73 20 49 6e 70 75 74 41 tionMap.AddActionMap(this.InputA
15e0 63 74 69 6f 6e 41 73 73 65 74 20 61 73 73 65 74 2c 20 73 74 72 69 6e 67 20 6e 61 6d 65 29 0d 0a ctionAsset.asset,.string.name)..
1600 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 73 73 65 74 ........{..............if.(asset
1620 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 .==.null)..................throw
1640 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f .new.ArgumentNullException(nameo
1660 66 28 61 73 73 65 74 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 f(asset));..............if.(stri
1680 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 6e 61 6d 65 29 29 0d 0a 20 20 20 20 20 20 20 ng.IsNullOrEmpty(name)).........
16a0 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 .........throw.new.ArgumentNullE
16c0 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 6e 61 6d 65 29 29 3b 0d 0a 20 20 20 20 20 20 20 xception(nameof(name));.........
16e0 20 20 20 20 20 69 66 20 28 61 73 73 65 74 2e 46 69 6e 64 41 63 74 69 6f 6e 4d 61 70 28 6e 61 6d .....if.(asset.FindActionMap(nam
1700 65 29 20 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 e).!=.null)..................thr
1720 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e ow.new.InvalidOperationException
1740 28 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 22 41 6e 20 61 63 74 69 (......................$"An.acti
1760 6f 6e 20 6d 61 70 20 63 61 6c 6c 65 64 20 27 7b 6e 61 6d 65 7d 27 20 61 6c 72 65 61 64 79 20 65 on.map.called.'{name}'.already.e
1780 78 69 73 74 73 20 69 6e 20 74 68 65 20 61 73 73 65 74 22 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 xists.in.the.asset");...........
17a0 20 20 20 20 20 76 61 72 20 6d 61 70 20 3d 20 6e 65 77 20 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 .....var.map.=.new.InputActionMa
17c0 70 28 6e 61 6d 65 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 6d 61 70 2e 47 65 6e 65 72 61 p(name);..............map.Genera
17e0 74 65 49 64 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 73 73 65 74 2e 41 64 64 41 63 teId();..............asset.AddAc
1800 74 69 6f 6e 4d 61 70 28 6d 61 70 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 tionMap(map);..............retur
1820 6e 20 6d 61 70 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f n.map;..........}............///
1840 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 41 64 64 20 61 6e 20 61 .<summary>..........///.Add.an.a
1860 63 74 69 6f 6e 20 6d 61 70 20 74 6f 20 74 68 65 20 61 73 73 65 74 2e 0d 0a 20 20 20 20 20 20 20 ction.map.to.the.asset..........
1880 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 .///.</summary>..........///.<pa
18a0 72 61 6d 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 3e 41 73 73 65 74 20 74 6f 20 61 64 64 20 74 68 ram.name="asset">Asset.to.add.th
18c0 65 20 6d 61 70 20 74 6f 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c e.map.to.</param>..........///.<
18e0 70 61 72 61 6d 20 6e 61 6d 65 3d 22 6d 61 70 22 3e 41 20 6e 61 6d 65 64 20 61 63 74 69 6f 6e 20 param.name="map">A.named.action.
1900 6d 61 70 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 map.</param>..........///.<excep
1920 74 69 6f 6e 20 63 72 65 66 3d 22 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e tion.cref="ArgumentNullException
1940 22 3e 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6d 61 70 22 2f 3e 20 6f 72 20 3c 70 61 72 "><paramref.name="map"/>.or.<par
1960 61 6d 72 65 66 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 2f 3e 20 69 73 20 3c 63 3e 6e 75 6c 6c 3c amref.name="asset"/>.is.<c>null<
1980 2f 63 3e 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 /c>.</exception>..........///.<e
19a0 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 xception.cref="InvalidOperationE
19c0 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6d 61 70 22 2f 3e xception"><paramref.name="map"/>
19e0 20 68 61 73 20 6e 6f 20 6e 61 6d 65 20 6f 72 20 61 73 73 65 74 20 61 6c 72 65 61 64 79 20 63 6f .has.no.name.or.asset.already.co
1a00 6e 74 61 69 6e 73 20 61 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 6d 61 70 20 77 69 74 68 20 74 ntains.a..........///.map.with.t
1a20 68 65 20 73 61 6d 65 20 6e 61 6d 65 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 he.same.name.</exception>.......
1a40 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c 73 6f 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f ...///.<seealso.cref="InputActio
1a60 6e 41 73 73 65 74 2e 61 63 74 69 6f 6e 4d 61 70 73 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 70 75 nAsset.actionMaps"/>..........pu
1a80 62 6c 69 63 20 73 74 61 74 69 63 20 76 6f 69 64 20 41 64 64 41 63 74 69 6f 6e 4d 61 70 28 74 68 blic.static.void.AddActionMap(th
1aa0 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 20 61 73 73 65 74 2c 20 49 6e 70 75 74 is.InputActionAsset.asset,.Input
1ac0 41 63 74 69 6f 6e 4d 61 70 20 6d 61 70 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 ActionMap.map)..........{.......
1ae0 20 20 20 20 20 20 20 69 66 20 28 61 73 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 .......if.(asset.==.null).......
1b00 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c ...........throw.new.ArgumentNul
1b20 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 73 73 65 74 29 29 3b 0d 0a 20 20 20 20 lException(nameof(asset));......
1b40 20 20 20 20 20 20 20 20 69 66 20 28 6d 61 70 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 ........if.(map.==.null)........
1b60 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c ..........throw.new.ArgumentNull
1b80 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 6d 61 70 29 29 3b 0d 0a 20 20 20 20 20 20 20 Exception(nameof(map));.........
1ba0 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 6d 61 .....if.(string.IsNullOrEmpty(ma
1bc0 70 2e 6e 61 6d 65 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 p.name))..................throw.
1be0 6e 65 77 20 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 28 22 4d new.InvalidOperationException("M
1c00 61 70 73 20 61 64 64 65 64 20 74 6f 20 61 6e 20 69 6e 70 75 74 20 61 63 74 69 6f 6e 20 61 73 73 aps.added.to.an.input.action.ass
1c20 65 74 20 6d 75 73 74 20 62 65 20 6e 61 6d 65 64 22 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 et.must.be.named");.............
1c40 20 69 66 20 28 6d 61 70 2e 61 73 73 65 74 20 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 .if.(map.asset.!=.null).........
1c60 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 .........throw.new.InvalidOperat
1c80 69 6f 6e 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 ionException(...................
1ca0 20 20 20 24 22 43 61 6e 6e 6f 74 20 61 64 64 20 6d 61 70 20 27 7b 6d 61 70 7d 27 20 74 6f 20 61 ...$"Cannot.add.map.'{map}'.to.a
1cc0 73 73 65 74 20 27 7b 61 73 73 65 74 7d 27 20 61 73 20 69 74 20 68 61 73 20 61 6c 72 65 61 64 79 sset.'{asset}'.as.it.has.already
1ce0 20 62 65 65 6e 20 61 64 64 65 64 20 74 6f 20 61 73 73 65 74 20 27 7b 6d 61 70 2e 61 73 73 65 74 .been.added.to.asset.'{map.asset
1d00 7d 27 22 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 2f 52 45 56 49 45 57 3a 20 73 }'");..............////REVIEW:.s
1d20 6f 6d 65 20 6f 66 20 74 68 65 20 72 75 6c 65 73 20 68 65 72 65 20 73 65 65 6d 20 73 74 75 70 69 ome.of.the.rules.here.seem.stupi
1d40 64 3b 20 6a 75 73 74 20 72 65 70 6c 61 63 65 3f 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 d;.just.replace?..............if
1d60 20 28 61 73 73 65 74 2e 46 69 6e 64 41 63 74 69 6f 6e 4d 61 70 28 6d 61 70 2e 6e 61 6d 65 29 20 .(asset.FindActionMap(map.name).
1d80 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 !=.null)..................throw.
1da0 6e 65 77 20 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 28 0d 0a new.InvalidOperationException(..
1dc0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 22 41 6e 20 61 63 74 69 6f 6e 20 ....................$"An.action.
1de0 6d 61 70 20 63 61 6c 6c 65 64 20 27 7b 6d 61 70 2e 6e 61 6d 65 7d 27 20 61 6c 72 65 61 64 79 20 map.called.'{map.name}'.already.
1e00 65 78 69 73 74 73 20 69 6e 20 74 68 65 20 61 73 73 65 74 22 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 exists.in.the.asset");..........
1e20 20 20 20 20 20 20 41 72 72 61 79 48 65 6c 70 65 72 73 2e 41 70 70 65 6e 64 28 72 65 66 20 61 73 ......ArrayHelpers.Append(ref.as
1e40 73 65 74 2e 6d 5f 41 63 74 69 6f 6e 4d 61 70 73 2c 20 6d 61 70 29 3b 0d 0a 20 20 20 20 20 20 20 set.m_ActionMaps,.map);.........
1e60 20 20 20 20 20 6d 61 70 2e 6d 5f 41 73 73 65 74 20 3d 20 61 73 73 65 74 3b 0d 0a 20 20 20 20 20 .....map.m_Asset.=.asset;.......
1e80 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 ...}............///.<summary>...
1ea0 20 20 20 20 20 20 20 2f 2f 2f 20 52 65 6d 6f 76 65 20 74 68 65 20 67 69 76 65 6e 20 61 63 74 69 .......///.Remove.the.given.acti
1ec0 6f 6e 20 6d 61 70 20 66 72 6f 6d 20 74 68 65 20 61 73 73 65 74 2e 0d 0a 20 20 20 20 20 20 20 20 on.map.from.the.asset...........
1ee0 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 ///.</summary>..........///.<par
1f00 61 6d 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 3e 41 73 73 65 74 20 74 6f 20 61 64 64 20 74 68 65 am.name="asset">Asset.to.add.the
1f20 20 61 63 74 69 6f 6e 20 6d 61 70 20 74 6f 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 .action.map.to.</param>.........
1f40 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 6d 61 70 22 3e 41 6e 20 61 63 74 69 6f 6e .///.<param.name="map">An.action
1f60 20 6d 61 70 2e 20 49 66 20 74 68 65 20 67 69 76 65 6e 20 6d 61 70 20 69 73 20 6e 6f 74 20 70 61 .map..If.the.given.map.is.not.pa
1f80 72 74 20 6f 66 20 74 68 65 20 61 73 73 65 74 2c 20 74 68 65 20 6d 65 74 68 6f 64 0d 0a 20 20 20 rt.of.the.asset,.the.method.....
1fa0 20 20 20 20 20 2f 2f 2f 20 64 6f 65 73 20 6e 6f 74 68 69 6e 67 2e 3c 2f 70 61 72 61 6d 3e 0d 0a .....///.does.nothing.</param>..
1fc0 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 41 72 67 ........///.<exception.cref="Arg
1fe0 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 65 66 20 6e 61 umentNullException"><paramref.na
2000 6d 65 3d 22 61 73 73 65 74 22 2f 3e 20 6f 72 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 me="asset"/>.or.<paramref.name="
2020 6d 61 70 22 2f 3e 20 69 73 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 2e 3c 2f 65 78 63 65 70 74 69 6f map"/>.is.<c>null</c>.</exceptio
2040 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d n>..........///.<exception.cref=
2060 22 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 "InvalidOperationException"><par
2080 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6d 61 70 22 2f 3e 20 69 73 20 63 75 72 72 65 6e 74 6c 79 20 amref.name="map"/>.is.currently.
20a0 65 6e 61 62 6c 65 64 20 28 73 65 65 20 3c 73 65 65 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 63 enabled.(see.<see..........///.c
20c0 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 70 2e 65 6e 61 62 6c 65 64 22 2f 3e 29 2e ref="InputActionMap.enabled"/>).
20e0 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c </exception>..........///.<seeal
2100 73 6f 20 63 72 65 66 3d 22 52 65 6d 6f 76 65 41 63 74 69 6f 6e 4d 61 70 28 49 6e 70 75 74 41 63 so.cref="RemoveActionMap(InputAc
2120 74 69 6f 6e 41 73 73 65 74 2c 73 74 72 69 6e 67 29 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f tionAsset,string)"/>..........//
2140 2f 20 3c 73 65 65 61 6c 73 6f 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 /.<seealso.cref="InputActionAsse
2160 74 2e 61 63 74 69 6f 6e 4d 61 70 73 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 t.actionMaps"/>..........public.
2180 73 74 61 74 69 63 20 76 6f 69 64 20 52 65 6d 6f 76 65 41 63 74 69 6f 6e 4d 61 70 28 74 68 69 73 static.void.RemoveActionMap(this
21a0 20 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 20 61 73 73 65 74 2c 20 49 6e 70 75 74 41 63 .InputActionAsset.asset,.InputAc
21c0 74 69 6f 6e 4d 61 70 20 6d 61 70 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 tionMap.map)..........{.........
21e0 20 20 20 20 20 69 66 20 28 61 73 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 .....if.(asset.==.null).........
2200 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 .........throw.new.ArgumentNullE
2220 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 73 73 65 74 29 29 3b 0d 0a 20 20 20 20 20 20 xception(nameof(asset));........
2240 20 20 20 20 20 20 69 66 20 28 6d 61 70 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 ......if.(map.==.null)..........
2260 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 ........throw.new.ArgumentNullEx
2280 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 6d 61 70 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 ception(nameof(map));...........
22a0 20 20 20 69 66 20 28 6d 61 70 2e 65 6e 61 62 6c 65 64 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 ...if.(map.enabled).............
22c0 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 .....throw.new.InvalidOperationE
22e0 78 63 65 70 74 69 6f 6e 28 22 43 61 6e 6e 6f 74 20 72 65 6d 6f 76 65 20 61 6e 20 61 63 74 69 6f xception("Cannot.remove.an.actio
2300 6e 20 6d 61 70 20 66 72 6f 6d 20 74 68 65 20 61 73 73 65 74 20 77 68 69 6c 65 20 69 74 20 69 73 n.map.from.the.asset.while.it.is
2320 20 65 6e 61 62 6c 65 64 22 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 49 67 .enabled");................//.Ig
2340 6e 6f 72 65 20 69 66 20 6e 6f 74 20 70 61 72 74 20 6f 66 20 74 68 69 73 20 61 73 73 65 74 2e 0d nore.if.not.part.of.this.asset..
2360 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 61 70 2e 6d 5f 41 73 73 65 74 20 21 3d 20 .............if.(map.m_Asset.!=.
2380 61 73 73 65 74 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0d asset)..................return;.
23a0 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 41 72 72 61 79 48 65 6c 70 65 72 73 2e 45 72 61 73 ...............ArrayHelpers.Eras
23c0 65 28 72 65 66 20 61 73 73 65 74 2e 6d 5f 41 63 74 69 6f 6e 4d 61 70 73 2c 20 6d 61 70 29 3b 0d e(ref.asset.m_ActionMaps,.map);.
23e0 0a 20 20 20 20 20 20 20 20 20 20 20 20 6d 61 70 2e 6d 5f 41 73 73 65 74 20 3d 20 6e 75 6c 6c 3b .............map.m_Asset.=.null;
2400 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d ..........}............///.<summ
2420 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 52 65 6d 6f 76 65 20 74 68 65 20 61 63 74 ary>..........///.Remove.the.act
2440 69 6f 6e 20 6d 61 70 20 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 6e 61 6d 65 20 6f 72 20 49 ion.map.with.the.given.name.or.I
2460 44 20 66 72 6f 6d 20 74 68 65 20 61 73 73 65 74 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c D.from.the.asset...........///.<
2480 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 /summary>..........///.<param.na
24a0 6d 65 3d 22 61 73 73 65 74 22 3e 41 73 73 65 74 20 74 6f 20 72 65 6d 6f 76 65 20 74 68 65 20 61 me="asset">Asset.to.remove.the.a
24c0 63 74 69 6f 6e 20 6d 61 70 20 66 72 6f 6d 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 ction.map.from.</param>.........
24e0 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 6e 61 6d 65 4f 72 49 64 22 3e 54 68 65 20 .///.<param.name="nameOrId">The.
2500 6e 61 6d 65 20 6f 72 20 49 44 20 28 73 65 65 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 name.or.ID.(see.<see.cref="Input
2520 41 63 74 69 6f 6e 4d 61 70 2e 69 64 22 2f 3e 29 20 6f 66 20 61 20 6d 61 70 20 69 6e 20 74 68 65 ActionMap.id"/>).of.a.map.in.the
2540 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 61 73 73 65 74 2e 20 4e 6f 74 65 20 74 68 61 74 20 6c ..........///.asset..Note.that.l
2560 6f 6f 6b 75 70 20 69 73 20 63 61 73 65 2d 69 6e 73 65 6e 73 69 74 69 76 65 2e 20 49 66 20 6e 6f ookup.is.case-insensitive..If.no
2580 20 6d 61 70 20 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 6e 61 6d 65 20 6f 72 20 49 44 20 69 .map.with.the.given.name.or.ID.i
25a0 73 20 66 6f 75 6e 64 2c 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 74 68 65 20 6d 65 74 68 6f 64 s.found,..........///.the.method
25c0 20 64 6f 65 73 20 6e 6f 74 68 69 6e 67 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 .does.nothing.</param>..........
25e0 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 41 72 67 75 6d 65 6e 74 4e 75 6c ///.<exception.cref="ArgumentNul
2600 6c 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 61 73 73 65 lException"><paramref.name="asse
2620 74 22 2f 3e 20 6f 72 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6e 61 6d 65 4f 72 49 64 t"/>.or.<paramref.name="nameOrId
2640 22 2f 3e 20 69 73 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d "/>.is.<c>null</c>.</exception>.
2660 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 49 6e .........///.<exception.cref="In
2680 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 22 3e 54 68 65 20 6d 61 70 validOperationException">The.map
26a0 20 72 65 66 65 72 65 6e 63 65 64 20 62 79 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6e .referenced.by.<paramref.name="n
26c0 61 6d 65 4f 72 49 64 22 2f 3e 20 69 73 20 63 75 72 72 65 6e 74 6c 79 20 65 6e 61 62 6c 65 64 0d ameOrId"/>.is.currently.enabled.
26e0 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 28 73 65 65 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 .........///.(see.<see.cref="Inp
2700 75 74 41 63 74 69 6f 6e 4d 61 70 2e 65 6e 61 62 6c 65 64 22 2f 3e 29 2e 3c 2f 65 78 63 65 70 74 utActionMap.enabled"/>).</except
2720 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c 73 6f 20 63 72 65 66 3d ion>..........///.<seealso.cref=
2740 22 52 65 6d 6f 76 65 41 63 74 69 6f 6e 4d 61 70 28 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 "RemoveActionMap(InputActionAsse
2760 74 2c 73 74 72 69 6e 67 29 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c t,string)"/>..........///.<seeal
2780 73 6f 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 2e 61 63 74 69 6f 6e so.cref="InputActionAsset.action
27a0 4d 61 70 73 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 76 Maps"/>..........public.static.v
27c0 6f 69 64 20 52 65 6d 6f 76 65 41 63 74 69 6f 6e 4d 61 70 28 74 68 69 73 20 49 6e 70 75 74 41 63 oid.RemoveActionMap(this.InputAc
27e0 74 69 6f 6e 41 73 73 65 74 20 61 73 73 65 74 2c 20 73 74 72 69 6e 67 20 6e 61 6d 65 4f 72 49 64 tionAsset.asset,.string.nameOrId
2800 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 73 )..........{..............if.(as
2820 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 set.==.null)..................th
2840 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 row.new.ArgumentNullException(na
2860 6d 65 6f 66 28 61 73 73 65 74 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e meof(asset));..............if.(n
2880 61 6d 65 4f 72 49 64 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 ameOrId.==.null)................
28a0 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f ..throw.new.ArgumentNullExceptio
28c0 6e 28 6e 61 6d 65 6f 66 28 6e 61 6d 65 4f 72 49 64 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 n(nameof(nameOrId));............
28e0 20 20 76 61 72 20 6d 61 70 20 3d 20 61 73 73 65 74 2e 46 69 6e 64 41 63 74 69 6f 6e 4d 61 70 28 ..var.map.=.asset.FindActionMap(
2900 6e 61 6d 65 4f 72 49 64 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 61 70 20 nameOrId);..............if.(map.
2920 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 73 73 65 74 2e !=.null)..................asset.
2940 52 65 6d 6f 76 65 41 63 74 69 6f 6e 4d 61 70 28 6d 61 70 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d RemoveActionMap(map);..........}
2960 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 2f 54 4f 44 4f 3a 20 61 64 64 20 6d 65 74 68 6f 64 ............////TODO:.add.method
2980 20 74 6f 20 61 64 64 20 61 6e 20 65 78 69 73 74 69 6e 67 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 .to.add.an.existing.InputAction.
29a0 74 6f 20 61 20 6d 61 70 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 to.a.map............public.stati
29c0 63 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 41 64 64 41 63 74 69 6f 6e 28 74 68 69 73 20 49 6e 70 c.InputAction.AddAction(this.Inp
29e0 75 74 41 63 74 69 6f 6e 4d 61 70 20 6d 61 70 2c 20 73 74 72 69 6e 67 20 6e 61 6d 65 2c 20 49 6e utActionMap.map,.string.name,.In
2a00 70 75 74 41 63 74 69 6f 6e 54 79 70 65 20 74 79 70 65 20 3d 20 64 65 66 61 75 6c 74 2c 20 73 74 putActionType.type.=.default,.st
2a20 72 69 6e 67 20 62 69 6e 64 69 6e 67 20 3d 20 6e 75 6c 6c 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 ring.binding.=.null,............
2a40 20 20 73 74 72 69 6e 67 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 20 3d 20 6e 75 6c 6c 2c 20 73 74 ..string.interactions.=.null,.st
2a60 72 69 6e 67 20 70 72 6f 63 65 73 73 6f 72 73 20 3d 20 6e 75 6c 6c 2c 20 73 74 72 69 6e 67 20 67 ring.processors.=.null,.string.g
2a80 72 6f 75 70 73 20 3d 20 6e 75 6c 6c 2c 20 73 74 72 69 6e 67 20 65 78 70 65 63 74 65 64 43 6f 6e roups.=.null,.string.expectedCon
2aa0 74 72 6f 6c 4c 61 79 6f 75 74 20 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 trolLayout.=.null)..........{...
2ac0 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 61 70 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 ...........if.(map.==.null).....
2ae0 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e .............throw.new.ArgumentN
2b00 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 6d 61 70 29 29 3b 0d 0a 20 20 20 20 ullException(nameof(map));......
2b20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 ........if.(string.IsNullOrEmpty
2b40 28 6e 61 6d 65 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e (name))..................throw.n
2b60 65 77 20 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 22 41 63 74 69 6f 6e 20 6d 75 73 ew.ArgumentException("Action.mus
2b80 74 20 68 61 76 65 20 6e 61 6d 65 22 2c 20 6e 61 6d 65 6f 66 28 6e 61 6d 65 29 29 3b 0d 0a 20 20 t.have.name",.nameof(name));....
2ba0 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 61 70 2e 65 6e 61 62 6c 65 64 29 0d 0a 20 20 20 20 ..........if.(map.enabled)......
2bc0 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 4f 70 65 ............throw.new.InvalidOpe
2be0 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 rationException(................
2c00 20 20 20 20 20 20 24 22 43 61 6e 6e 6f 74 20 61 64 64 20 61 63 74 69 6f 6e 20 27 7b 6e 61 6d 65 ......$"Cannot.add.action.'{name
2c20 7d 27 20 74 6f 20 6d 61 70 20 27 7b 6d 61 70 7d 27 20 77 68 69 6c 65 20 69 74 20 74 68 65 20 6d }'.to.map.'{map}'.while.it.the.m
2c40 61 70 20 69 73 20 65 6e 61 62 6c 65 64 22 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 ap.is.enabled");..............if
2c60 20 28 6d 61 70 2e 46 69 6e 64 41 63 74 69 6f 6e 28 6e 61 6d 65 29 20 21 3d 20 6e 75 6c 6c 29 0d .(map.FindAction(name).!=.null).
2c80 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c .................throw.new.Inval
2ca0 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 20 20 idOperationException(...........
2cc0 20 20 20 20 20 20 20 20 20 20 20 24 22 43 61 6e 6e 6f 74 20 61 64 64 20 61 63 74 69 6f 6e 20 77 ...........$"Cannot.add.action.w
2ce0 69 74 68 20 64 75 70 6c 69 63 61 74 65 20 6e 61 6d 65 20 27 7b 6e 61 6d 65 7d 27 20 74 6f 20 73 ith.duplicate.name.'{name}'.to.s
2d00 65 74 20 27 7b 6d 61 70 2e 6e 61 6d 65 7d 27 22 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 et.'{map.name}'");..............
2d20 20 20 2f 2f 20 41 70 70 65 6e 64 20 61 63 74 69 6f 6e 20 74 6f 20 61 72 72 61 79 2e 0d 0a 20 20 ..//.Append.action.to.array.....
2d40 20 20 20 20 20 20 20 20 20 20 76 61 72 20 61 63 74 69 6f 6e 20 3d 20 6e 65 77 20 49 6e 70 75 74 ..........var.action.=.new.Input
2d60 41 63 74 69 6f 6e 28 6e 61 6d 65 2c 20 74 79 70 65 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 Action(name,.type)..............
2d80 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 65 78 70 65 63 74 65 64 43 6f 6e 74 72 {..................expectedContr
2da0 6f 6c 54 79 70 65 20 3d 20 65 78 70 65 63 74 65 64 43 6f 6e 74 72 6f 6c 4c 61 79 6f 75 74 0d 0a olType.=.expectedControlLayout..
2dc0 20 20 20 20 20 20 20 20 20 20 20 20 7d 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 63 74 69 ............};..............acti
2de0 6f 6e 2e 47 65 6e 65 72 61 74 65 49 64 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 41 72 on.GenerateId();..............Ar
2e00 72 61 79 48 65 6c 70 65 72 73 2e 41 70 70 65 6e 64 28 72 65 66 20 6d 61 70 2e 6d 5f 41 63 74 69 rayHelpers.Append(ref.map.m_Acti
2e20 6f 6e 73 2c 20 61 63 74 69 6f 6e 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 63 74 69 6f ons,.action);..............actio
2e40 6e 2e 6d 5f 41 63 74 69 6f 6e 4d 61 70 20 3d 20 6d 61 70 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 n.m_ActionMap.=.map;............
2e60 20 20 20 20 2f 2f 2f 2f 54 4f 44 4f 3a 20 6d 61 6b 65 20 73 75 72 65 20 77 65 20 62 6c 61 73 74 ....////TODO:.make.sure.we.blast
2e80 20 6f 75 74 20 65 78 69 73 74 69 6e 67 20 61 63 74 69 6f 6e 20 6d 61 70 20 73 74 61 74 65 0d 0a .out.existing.action.map.state..
2ea0 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 41 64 64 20 62 69 6e 64 69 6e 67 2c 20 69 66 ..............//.Add.binding,.if
2ec0 20 73 75 70 70 6c 69 65 64 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 73 74 72 .supplied...............if.(!str
2ee0 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 62 69 6e 64 69 6e 67 29 29 0d 0a 20 20 20 ing.IsNullOrEmpty(binding)).....
2f00 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 63 74 69 .........{..................acti
2f20 6f 6e 2e 41 64 64 42 69 6e 64 69 6e 67 28 62 69 6e 64 69 6e 67 2c 20 69 6e 74 65 72 61 63 74 69 on.AddBinding(binding,.interacti
2f40 6f 6e 73 3a 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 2c 20 70 72 6f 63 65 73 73 6f 72 73 3a 20 70 ons:.interactions,.processors:.p
2f60 72 6f 63 65 73 73 6f 72 73 2c 20 67 72 6f 75 70 73 3a 20 67 72 6f 75 70 73 29 3b 0d 0a 20 20 20 rocessors,.groups:.groups);.....
2f80 20 20 20 20 20 20 20 20 20 7d 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 65 6c 73 65 0d 0a 20 20 .........}..............else....
2fa0 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 ..........{..................if.
2fc0 28 21 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 67 72 6f 75 70 73 29 29 0d (!string.IsNullOrEmpty(groups)).
2fe0 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 .....................throw.new.A
3000 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 rgumentException(...............
3020 20 20 20 20 20 20 20 20 20 20 20 24 22 4e 6f 20 62 69 6e 64 69 6e 67 20 70 61 74 68 20 77 61 73 ...........$"No.binding.path.was
3040 20 73 70 65 63 69 66 69 65 64 20 66 6f 72 20 61 63 74 69 6f 6e 20 27 7b 61 63 74 69 6f 6e 7d 27 .specified.for.action.'{action}'
3060 20 62 75 74 20 67 72 6f 75 70 73 20 77 61 73 20 73 70 65 63 69 66 69 65 64 20 28 27 7b 67 72 6f .but.groups.was.specified.('{gro
3080 75 70 73 7d 27 29 3b 20 63 61 6e 6e 6f 74 20 61 70 70 6c 79 20 67 72 6f 75 70 73 20 77 69 74 68 ups}');.cannot.apply.groups.with
30a0 6f 75 74 20 62 69 6e 64 69 6e 67 22 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 out.binding",...................
30c0 20 20 20 20 20 20 20 6e 61 6d 65 6f 66 28 67 72 6f 75 70 73 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 .......nameof(groups));.........
30e0 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 49 66 20 6e 6f 20 62 69 6e 64 69 6e 67 20 68 61 73 20 ...........//.If.no.binding.has.
3100 62 65 65 6e 20 73 75 70 70 6c 69 65 64 20 62 75 74 20 74 68 65 72 65 20 61 72 65 20 69 6e 74 65 been.supplied.but.there.are.inte
3120 72 61 63 74 69 6f 6e 73 20 61 6e 64 20 70 72 6f 63 65 73 73 6f 72 73 2c 20 74 68 65 79 20 67 6f ractions.and.processors,.they.go
3140 20 6f 6e 20 74 68 65 20 61 63 74 69 6f 6e 20 69 74 73 65 6c 66 2e 0d 0a 20 20 20 20 20 20 20 20 .on.the.action.itself...........
3160 20 20 20 20 20 20 20 20 61 63 74 69 6f 6e 2e 6d 5f 49 6e 74 65 72 61 63 74 69 6f 6e 73 20 3d 20 ........action.m_Interactions.=.
3180 69 6e 74 65 72 61 63 74 69 6f 6e 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 interactions;..................a
31a0 63 74 69 6f 6e 2e 6d 5f 50 72 6f 63 65 73 73 6f 72 73 20 3d 20 70 72 6f 63 65 73 73 6f 72 73 3b ction.m_Processors.=.processors;
31c0 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 ..............}................r
31e0 65 74 75 72 6e 20 61 63 74 69 6f 6e 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 eturn.action;..........}........
3200 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 52 ....///.<summary>..........///.R
3220 65 6d 6f 76 65 20 74 68 65 20 67 69 76 65 6e 20 61 63 74 69 6f 6e 20 66 72 6f 6d 20 69 74 73 20 emove.the.given.action.from.its.
3240 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 70 22 2f 3e 2e 0d 0a 20 <see.cref="InputActionMap"/>....
3260 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f .......///.</summary>........../
3280 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 61 63 74 69 6f 6e 22 3e 41 6e 20 69 6e 70 75 74 //.<param.name="action">An.input
32a0 20 61 63 74 69 6f 6e 20 74 68 61 74 20 69 73 20 70 61 72 74 20 6f 66 20 61 6e 20 3c 73 65 65 20 .action.that.is.part.of.an.<see.
32c0 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 70 22 2f 3e 2e 3c 2f 70 61 72 61 6d 3e cref="InputActionMap"/>.</param>
32e0 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 41 ..........///.<exception.cref="A
3300 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 65 66 20 rgumentNullException"><paramref.
3320 6e 61 6d 65 3d 22 61 63 74 69 6f 6e 22 2f 3e 20 69 73 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 2e 3c name="action"/>.is.<c>null</c>.<
3340 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 /exception>..........///.<except
3360 69 6f 6e 20 63 72 65 66 3d 22 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 ion.cref="ArgumentException"><pa
3380 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 61 63 74 69 6f 6e 22 2f 3e 20 69 73 20 70 61 72 74 20 6f ramref.name="action"/>.is.part.o
33a0 66 20 61 6e 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 70 22 2f f.an.<see.cref="InputActionMap"/
33c0 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 74 68 61 74 20 68 61 73 20 61 74 20 6c 65 61 73 74 >..........///.that.has.at.least
33e0 20 6f 6e 65 20 65 6e 61 62 6c 65 64 20 61 63 74 69 6f 6e 20 2d 6f 72 2d 20 3c 70 61 72 61 6d 72 .one.enabled.action.-or-.<paramr
3400 65 66 20 6e 61 6d 65 3d 22 61 63 74 69 6f 6e 22 2f 3e 20 69 73 20 61 20 73 74 61 6e 64 61 6c 6f ef.name="action"/>.is.a.standalo
3420 6e 65 20 61 63 74 69 6f 6e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 74 68 61 74 20 69 73 20 6e ne.action..........///.that.is.n
3440 6f 74 20 70 61 72 74 20 6f 66 20 61 6e 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 ot.part.of.an.<see.cref="InputAc
3460 74 69 6f 6e 4d 61 70 22 2f 3e 20 61 6e 64 20 74 68 75 73 20 63 61 6e 6e 6f 74 20 62 65 20 72 65 tionMap"/>.and.thus.cannot.be.re
3480 6d 6f 76 65 64 20 66 72 6f 6d 20 61 6e 79 74 68 69 6e 67 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e moved.from.anything.</exception>
34a0 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 20 20 20 20 ..........///.<remarks>.........
34c0 20 2f 2f 2f 20 41 66 74 65 72 20 72 65 6d 6f 76 61 6c 2c 20 74 68 65 20 61 63 74 69 6f 6e 27 73 .///.After.removal,.the.action's
34e0 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 2e 61 63 74 69 6f 6e 4d 61 .<see.cref="InputAction.actionMa
3500 70 22 2f 3e 20 77 69 6c 6c 20 62 65 20 73 65 74 20 74 6f 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 0d p"/>.will.be.set.to.<c>null</c>.
3520 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 61 6e 64 20 74 68 65 20 61 63 74 69 6f 6e 20 77 69 6c 6c .........///.and.the.action.will
3540 20 65 66 66 65 63 74 69 76 65 6c 79 20 62 65 63 6f 6d 65 20 61 20 73 74 61 6e 64 61 6c 6f 6e 65 .effectively.become.a.standalone
3560 20 61 63 74 69 6f 6e 20 74 68 61 74 20 69 73 20 6e 6f 74 20 61 73 73 6f 63 69 61 74 65 64 20 77 .action.that.is.not.associated.w
3580 69 74 68 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 61 6e 79 20 61 63 74 69 6f 6e 20 6d 61 70 2e ith..........///.any.action.map.
35a0 20 42 69 6e 64 69 6e 67 73 20 6f 6e 20 74 68 65 20 61 63 74 69 6f 6e 20 77 69 6c 6c 20 62 65 20 .Bindings.on.the.action.will.be.
35c0 70 72 65 73 65 72 76 65 64 2e 20 4f 6e 20 74 68 65 20 61 63 74 69 6f 6e 20 6d 61 70 2c 20 74 68 preserved..On.the.action.map,.th
35e0 65 20 62 69 6e 64 69 6e 67 73 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 66 6f 72 20 74 68 65 20 e.bindings..........///.for.the.
3600 61 63 74 69 6f 6e 20 77 69 6c 6c 20 62 65 20 72 65 6d 6f 76 65 64 2e 0d 0a 20 20 20 20 20 20 20 action.will.be.removed..........
3620 20 2f 2f 2f 20 3c 2f 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 .///.</remarks>..........///.<se
3640 65 61 6c 73 6f 20 63 72 65 66 3d 22 41 64 64 41 63 74 69 6f 6e 22 2f 3e 0d 0a 20 20 20 20 20 20 ealso.cref="AddAction"/>........
3660 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 76 6f 69 64 20 52 65 6d 6f 76 65 41 63 74 69 6f ..public.static.void.RemoveActio
3680 6e 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 29 0d 0a 20 20 20 20 n(this.InputAction.action)......
36a0 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 20 3d 3d ....{..............if.(action.==
36c0 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 .null)..................throw.ne
36e0 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 w.ArgumentNullException(nameof(a
3700 63 74 69 6f 6e 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 61 63 74 69 ction));................var.acti
3720 6f 6e 4d 61 70 20 3d 20 61 63 74 69 6f 6e 2e 61 63 74 69 6f 6e 4d 61 70 3b 0d 0a 20 20 20 20 20 onMap.=.action.actionMap;.......
3740 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 4d 61 70 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 .......if.(actionMap.==.null)...
3760 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e ...............throw.new.Argumen
3780 74 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 tException(.....................
37a0 20 24 22 41 63 74 69 6f 6e 20 27 7b 61 63 74 69 6f 6e 7d 27 20 64 6f 65 73 20 6e 6f 74 20 62 65 .$"Action.'{action}'.does.not.be
37c0 6c 6f 6e 67 20 74 6f 20 61 6e 20 61 63 74 69 6f 6e 20 6d 61 70 3b 20 6e 6f 77 68 65 72 65 20 74 long.to.an.action.map;.nowhere.t
37e0 6f 20 72 65 6d 6f 76 65 20 66 72 6f 6d 22 2c 20 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e 29 29 3b o.remove.from",.nameof(action));
3800 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 4d 61 70 2e 65 6e 61 62 ..............if.(actionMap.enab
3820 6c 65 64 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 led)..................throw.new.
3840 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 24 22 43 61 6e 6e 6f 74 20 72 65 6d 6f 76 ArgumentException($"Cannot.remov
3860 65 20 61 63 74 69 6f 6e 20 27 7b 61 63 74 69 6f 6e 7d 27 20 77 68 69 6c 65 20 69 74 73 20 61 63 e.action.'{action}'.while.its.ac
3880 74 69 6f 6e 20 6d 61 70 20 69 73 20 65 6e 61 62 6c 65 64 22 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 tion.map.is.enabled");..........
38a0 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 69 6e 67 73 46 6f 72 41 63 74 69 6f 6e 20 3d 20 61 63 ......var.bindingsForAction.=.ac
38c0 74 69 6f 6e 2e 62 69 6e 64 69 6e 67 73 2e 54 6f 41 72 72 61 79 28 29 3b 0d 0a 0d 0a 20 20 20 20 tion.bindings.ToArray();........
38e0 20 20 20 20 20 20 20 20 76 61 72 20 69 6e 64 65 78 20 3d 20 41 72 72 61 79 48 65 6c 70 65 72 73 ........var.index.=.ArrayHelpers
3900 2e 49 6e 64 65 78 4f 66 52 65 66 65 72 65 6e 63 65 28 61 63 74 69 6f 6e 4d 61 70 2e 6d 5f 41 63 .IndexOfReference(actionMap.m_Ac
3920 74 69 6f 6e 73 2c 20 61 63 74 69 6f 6e 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 44 65 62 tions,.action);..............Deb
3940 75 67 2e 41 73 73 65 72 74 28 69 6e 64 65 78 20 21 3d 20 2d 31 2c 20 22 43 6f 75 6c 64 20 6e 6f ug.Assert(index.!=.-1,."Could.no
3960 74 20 66 69 6e 64 20 61 63 74 69 6f 6e 20 69 6e 20 6d 61 70 22 29 3b 0d 0a 20 20 20 20 20 20 20 t.find.action.in.map");.........
3980 20 20 20 20 20 41 72 72 61 79 48 65 6c 70 65 72 73 2e 45 72 61 73 65 41 74 28 72 65 66 20 61 63 .....ArrayHelpers.EraseAt(ref.ac
39a0 74 69 6f 6e 4d 61 70 2e 6d 5f 41 63 74 69 6f 6e 73 2c 20 69 6e 64 65 78 29 3b 0d 0a 0d 0a 20 20 tionMap.m_Actions,.index);......
39c0 20 20 20 20 20 20 20 20 20 20 61 63 74 69 6f 6e 2e 6d 5f 41 63 74 69 6f 6e 4d 61 70 20 3d 20 6e ..........action.m_ActionMap.=.n
39e0 75 6c 6c 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 63 74 69 6f 6e 2e 6d 5f 53 69 6e 67 6c ull;..............action.m_Singl
3a00 65 74 6f 6e 41 63 74 69 6f 6e 42 69 6e 64 69 6e 67 73 20 3d 20 62 69 6e 64 69 6e 67 73 46 6f 72 etonActionBindings.=.bindingsFor
3a20 41 63 74 69 6f 6e 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 63 74 69 6f 6e 4d 61 70 Action;................actionMap
3a40 2e 43 6c 65 61 72 50 65 72 41 63 74 69 6f 6e 43 61 63 68 65 64 42 69 6e 64 69 6e 67 44 61 74 61 .ClearPerActionCachedBindingData
3a60 28 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 52 65 6d 6f 76 65 20 62 69 6e ();................//.Remove.bin
3a80 64 69 6e 67 73 20 74 6f 20 61 63 74 69 6f 6e 20 66 72 6f 6d 20 6d 61 70 2e 0d 0a 20 20 20 20 20 dings.to.action.from.map........
3aa0 20 20 20 20 20 20 20 76 61 72 20 6e 65 77 41 63 74 69 6f 6e 4d 61 70 42 69 6e 64 69 6e 67 43 6f .......var.newActionMapBindingCo
3ac0 75 6e 74 20 3d 20 61 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 2e 4c 65 6e 67 74 unt.=.actionMap.m_Bindings.Lengt
3ae0 68 20 2d 20 62 69 6e 64 69 6e 67 73 46 6f 72 41 63 74 69 6f 6e 2e 4c 65 6e 67 74 68 3b 0d 0a 20 h.-.bindingsForAction.Length;...
3b00 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6e 65 77 41 63 74 69 6f 6e 4d 61 70 42 69 6e 64 69 ...........if.(newActionMapBindi
3b20 6e 67 43 6f 75 6e 74 20 3d 3d 20 30 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 ngCount.==.0)..................a
3b40 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 20 3d 20 6e 75 6c 6c 3b 0d 0a 20 20 20 ctionMap.m_Bindings.=.null;.....
3b60 20 20 20 20 20 20 20 20 20 65 6c 73 65 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 .........else..............{....
3b80 20 20 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 6e 65 77 41 63 74 69 6f 6e 4d 61 70 42 69 ..............var.newActionMapBi
3ba0 6e 64 69 6e 67 73 20 3d 20 6e 65 77 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 5b 6e 65 77 41 63 74 ndings.=.new.InputBinding[newAct
3bc0 69 6f 6e 4d 61 70 42 69 6e 64 69 6e 67 43 6f 75 6e 74 5d 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 ionMapBindingCount];............
3be0 20 20 20 20 20 20 76 61 72 20 6f 6c 64 41 63 74 69 6f 6e 4d 61 70 42 69 6e 64 69 6e 67 73 20 3d ......var.oldActionMapBindings.=
3c00 20 61 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 3b 0d 0a 20 20 20 20 20 20 20 20 .actionMap.m_Bindings;..........
3c20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 69 6e 67 49 6e 64 65 78 20 3d 20 30 3b 0d 0a 20 ........var.bindingIndex.=.0;...
3c40 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 20 28 76 61 72 20 69 20 3d 20 30 3b 20 69 ...............for.(var.i.=.0;.i
3c60 20 3c 20 6f 6c 64 41 63 74 69 6f 6e 4d 61 70 42 69 6e 64 69 6e 67 73 2e 4c 65 6e 67 74 68 3b 20 .<.oldActionMapBindings.Length;.
3c80 2b 2b 69 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 ++i)..................{.........
3ca0 20 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 69 6e 67 20 3d 20 6f 6c 64 41 63 .............var.binding.=.oldAc
3cc0 74 69 6f 6e 4d 61 70 42 69 6e 64 69 6e 67 73 5b 69 5d 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 tionMapBindings[i];.............
3ce0 20 20 20 20 20 20 20 20 20 69 66 20 28 62 69 6e 64 69 6e 67 73 46 6f 72 41 63 74 69 6f 6e 2e 49 .........if.(bindingsForAction.I
3d00 6e 64 65 78 4f 66 28 62 20 3d 3e 20 62 20 3d 3d 20 62 69 6e 64 69 6e 67 29 20 3d 3d 20 2d 31 29 ndexOf(b.=>.b.==.binding).==.-1)
3d20 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6e 65 77 41 63 74 ..........................newAct
3d40 69 6f 6e 4d 61 70 42 69 6e 64 69 6e 67 73 5b 62 69 6e 64 69 6e 67 49 6e 64 65 78 2b 2b 5d 20 3d ionMapBindings[bindingIndex++].=
3d60 20 62 69 6e 64 69 6e 67 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 20 20 .binding;..................}....
3d80 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e ..............actionMap.m_Bindin
3da0 67 73 20 3d 20 6e 65 77 41 63 74 69 6f 6e 4d 61 70 42 69 6e 64 69 6e 67 73 3b 0d 0a 20 20 20 20 gs.=.newActionMapBindings;......
3dc0 20 20 20 20 20 20 20 20 7d 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 ........}..........}............
3de0 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 52 65 6d 6f 76 ///.<summary>..........///.Remov
3e00 65 20 74 68 65 20 61 63 74 69 6f 6e 20 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 6e 61 6d 65 e.the.action.with.the.given.name
3e20 20 66 72 6f 6d 20 74 68 65 20 61 73 73 65 74 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f .from.the.asset...........///.</
3e40 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d summary>..........///.<param.nam
3e60 65 3d 22 61 73 73 65 74 22 3e 41 73 73 65 74 20 74 6f 20 72 65 6d 6f 76 65 20 74 68 65 20 61 63 e="asset">Asset.to.remove.the.ac
3e80 74 69 6f 6e 20 66 72 6f 6d 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 tion.from.</param>..........///.
3ea0 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 6e 61 6d 65 4f 72 49 64 22 3e 4e 61 6d 65 20 6f 72 20 49 <param.name="nameOrId">Name.or.I
3ec0 44 20 6f 66 20 74 68 65 20 61 63 74 69 6f 6e 2e 20 53 65 65 20 3c 73 65 65 20 63 72 65 66 3d 22 D.of.the.action..See.<see.cref="
3ee0 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 2e 46 69 6e 64 41 63 74 69 6f 6e 28 73 74 72 69 InputActionAsset.FindAction(stri
3f00 6e 67 2c 62 6f 6f 6c 29 22 2f 3e 20 66 6f 72 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 64 65 74 ng,bool)"/>.for..........///.det
3f20 61 69 6c 73 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 ails.</param>..........///.<exce
3f40 70 74 69 6f 6e 20 63 72 65 66 3d 22 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f ption.cref="ArgumentNullExceptio
3f60 6e 22 3e 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 2f 3e 20 69 73 20 3c n"><paramref.name="asset"/>.is.<
3f80 63 3e 6e 75 6c 6c 3c 2f 63 3e 20 2d 6f 72 2d 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 c>null</c>.-or-.<paramref.name="
3fa0 6e 61 6d 65 4f 72 49 64 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 69 73 20 3c 63 3e 6e nameOrId"/>..........///.is.<c>n
3fc0 75 6c 6c 3c 2f 63 3e 20 6f 72 20 65 6d 70 74 79 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 ull</c>.or.empty.</exception>...
3fe0 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c 73 6f 20 63 72 65 66 3d 22 52 65 6d 6f 76 65 .......///.<seealso.cref="Remove
4000 41 63 74 69 6f 6e 28 49 6e 70 75 74 41 63 74 69 6f 6e 29 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 Action(InputAction)"/>..........
4020 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 76 6f 69 64 20 52 65 6d 6f 76 65 41 63 74 69 6f 6e 28 public.static.void.RemoveAction(
4040 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 20 61 73 73 65 74 2c 20 73 74 72 this.InputActionAsset.asset,.str
4060 69 6e 67 20 6e 61 6d 65 4f 72 49 64 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 ing.nameOrId)..........{........
4080 20 20 20 20 20 20 69 66 20 28 61 73 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 ......if.(asset.==.null)........
40a0 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c ..........throw.new.ArgumentNull
40c0 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 73 73 65 74 29 29 3b 0d 0a 20 20 20 20 20 Exception(nameof(asset));.......
40e0 20 20 20 20 20 20 20 69 66 20 28 6e 61 6d 65 4f 72 49 64 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 .......if.(nameOrId.==.null)....
4100 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 ..............throw.new.Argument
4120 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 6e 61 6d 65 4f 72 49 64 29 29 3b NullException(nameof(nameOrId));
4140 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 61 63 74 69 6f 6e 20 3d 20 61 73 73 65 74 ..............var.action.=.asset
4160 2e 46 69 6e 64 41 63 74 69 6f 6e 28 6e 61 6d 65 4f 72 49 64 29 3b 0d 0a 20 20 20 20 20 20 20 20 .FindAction(nameOrId);..........
4180 20 20 20 20 61 63 74 69 6f 6e 3f 2e 52 65 6d 6f 76 65 41 63 74 69 6f 6e 28 29 3b 0d 0a 20 20 20 ....action?.RemoveAction();.....
41a0 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d .....}............///.<summary>.
41c0 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 41 64 64 20 61 20 6e 65 77 20 62 69 6e 64 69 6e 67 20 74 .........///.Add.a.new.binding.t
41e0 6f 20 74 68 65 20 67 69 76 65 6e 20 61 63 74 69 6f 6e 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f o.the.given.action...........///
4200 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 .</summary>..........///.<param.
4220 6e 61 6d 65 3d 22 61 63 74 69 6f 6e 22 3e 41 63 74 69 6f 6e 20 74 6f 20 61 64 64 20 74 68 65 20 name="action">Action.to.add.the.
4240 62 69 6e 64 69 6e 67 20 74 6f 2e 20 49 66 20 74 68 65 20 61 63 74 69 6f 6e 20 69 73 20 70 61 72 binding.to..If.the.action.is.par
4260 74 20 6f 66 20 61 6e 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 t.of.an.<see.cref="InputActionMa
4280 70 22 2f 3e 2c 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 74 68 65 20 6e 65 77 6c 79 20 61 64 64 p"/>,..........///.the.newly.add
42a0 65 64 20 62 69 6e 64 69 6e 67 20 77 69 6c 6c 20 62 65 20 76 69 73 69 62 6c 65 20 6f 6e 20 3c 73 ed.binding.will.be.visible.on.<s
42c0 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 70 2e 62 69 6e 64 69 6e 67 73 ee.cref="InputActionMap.bindings
42e0 22 2f 3e 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d "/>.</param>..........///.<param
4300 20 6e 61 6d 65 3d 22 70 61 74 68 22 3e 42 69 6e 64 69 6e 67 20 70 61 74 68 20 73 74 72 69 6e 67 .name="path">Binding.path.string
4320 2e 20 53 65 65 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 42 69 6e 64 69 6e 67 2e 70 61 ..See.<see.cref="InputBinding.pa
4340 74 68 22 2f 3e 20 66 6f 72 20 64 65 74 61 69 6c 73 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 th"/>.for.details.</param>......
4360 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 69 6e 74 65 72 61 63 74 69 6f 6e ....///.<param.name="interaction
4380 73 22 3e 4f 70 74 69 6f 6e 61 6c 20 6c 69 73 74 20 6f 66 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 s">Optional.list.of.interactions
43a0 20 74 6f 20 61 70 70 6c 79 20 74 6f 20 74 68 65 20 62 69 6e 64 69 6e 67 2e 20 53 65 65 20 3c 73 .to.apply.to.the.binding..See.<s
43c0 65 65 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 63 72 65 66 3d 22 49 6e 70 75 74 42 69 6e 64 69 ee..........///.cref="InputBindi
43e0 6e 67 2e 69 6e 74 65 72 61 63 74 69 6f 6e 73 22 2f 3e 20 66 6f 72 20 64 65 74 61 69 6c 73 2e 3c ng.interactions"/>.for.details.<
4400 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 /param>..........///.<param.name
4420 3d 22 70 72 6f 63 65 73 73 6f 72 73 22 3e 4f 70 74 69 6f 6e 61 6c 20 6c 69 73 74 20 6f 66 20 70 ="processors">Optional.list.of.p
4440 72 6f 63 65 73 73 6f 72 73 20 74 6f 20 61 70 70 6c 79 20 74 6f 20 74 68 65 20 62 69 6e 64 69 6e rocessors.to.apply.to.the.bindin
4460 67 2e 20 53 65 65 20 3c 73 65 65 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 63 72 65 66 3d 22 49 g..See.<see..........///.cref="I
4480 6e 70 75 74 42 69 6e 64 69 6e 67 2e 70 72 6f 63 65 73 73 6f 72 73 22 2f 3e 20 66 6f 72 20 64 65 nputBinding.processors"/>.for.de
44a0 74 61 69 6c 73 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 tails.</param>..........///.<par
44c0 61 6d 20 6e 61 6d 65 3d 22 67 72 6f 75 70 73 22 3e 4f 70 74 69 6f 6e 61 6c 20 6c 69 73 74 20 6f am.name="groups">Optional.list.o
44e0 66 20 62 69 6e 64 69 6e 67 20 67 72 6f 75 70 73 20 74 68 61 74 20 73 68 6f 75 6c 64 20 62 65 20 f.binding.groups.that.should.be.
4500 61 73 73 69 67 6e 65 64 20 74 6f 20 74 68 65 20 62 69 6e 64 69 6e 67 2e 20 53 65 65 0d 0a 20 20 assigned.to.the.binding..See....
4520 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 42 69 6e 64 69 6e ......///.<see.cref="InputBindin
4540 67 2e 67 72 6f 75 70 73 22 2f 3e 20 66 6f 72 20 64 65 74 61 69 6c 73 2e 3c 2f 70 61 72 61 6d 3e g.groups"/>.for.details.</param>
4560 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 72 65 74 75 72 6e 73 3e 46 6c 75 65 6e 74 2d 73 74 ..........///.<returns>Fluent-st
4580 79 6c 65 20 73 79 6e 74 61 78 20 74 6f 20 66 75 72 74 68 65 72 20 63 6f 6e 66 69 67 75 72 65 20 yle.syntax.to.further.configure.
45a0 74 68 65 20 62 69 6e 64 69 6e 67 2e 3c 2f 72 65 74 75 72 6e 73 3e 0d 0a 20 20 20 20 20 20 20 20 the.binding.</returns>..........
45c0 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 41 64 64 42 public.static.BindingSyntax.AddB
45e0 69 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 2c 20 inding(this.InputAction.action,.
4600 73 74 72 69 6e 67 20 70 61 74 68 2c 20 73 74 72 69 6e 67 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 string.path,.string.interactions
4620 20 3d 20 6e 75 6c 6c 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 74 72 69 6e 67 20 70 72 6f .=.null,..............string.pro
4640 63 65 73 73 6f 72 73 20 3d 20 6e 75 6c 6c 2c 20 73 74 72 69 6e 67 20 67 72 6f 75 70 73 20 3d 20 cessors.=.null,.string.groups.=.
4660 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 null)..........{..............re
4680 74 75 72 6e 20 41 64 64 42 69 6e 64 69 6e 67 28 61 63 74 69 6f 6e 2c 20 6e 65 77 20 49 6e 70 75 turn.AddBinding(action,.new.Inpu
46a0 74 42 69 6e 64 69 6e 67 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 tBinding..............{.........
46c0 20 20 20 20 20 20 20 20 20 70 61 74 68 20 3d 20 70 61 74 68 2c 0d 0a 20 20 20 20 20 20 20 20 20 .........path.=.path,...........
46e0 20 20 20 20 20 20 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 20 3d 20 69 6e 74 65 72 61 63 74 69 6f .......interactions.=.interactio
4700 6e 73 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 70 72 6f 63 65 73 73 6f 72 73 20 ns,..................processors.
4720 3d 20 70 72 6f 63 65 73 73 6f 72 73 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 67 =.processors,..................g
4740 72 6f 75 70 73 20 3d 20 67 72 6f 75 70 73 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 29 3b 0d roups.=.groups..............});.
4760 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 .........}............///.<summa
4780 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 41 64 64 20 61 20 62 69 6e 64 69 6e 67 20 74 ry>..........///.Add.a.binding.t
47a0 68 61 74 20 72 65 66 65 72 65 6e 63 65 73 20 74 68 65 20 67 69 76 65 6e 20 3c 70 61 72 61 6d 72 hat.references.the.given.<paramr
47c0 65 66 20 6e 61 6d 65 3d 22 63 6f 6e 74 72 6f 6c 22 2f 3e 20 61 6e 64 20 74 72 69 67 67 65 72 73 ef.name="control"/>.and.triggers
47e0 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 74 68 65 20 67 69 76 65 6e 20 3c 73 65 65 61 6c 73 6f ..........///.the.given.<seealso
4800 20 63 72 65 66 3d 22 61 63 74 69 6f 6e 22 2f 3e 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c .cref="action"/>...........///.<
4820 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 /summary>..........///.<param.na
4840 6d 65 3d 22 61 63 74 69 6f 6e 22 3e 41 63 74 69 6f 6e 20 74 6f 20 74 72 69 67 67 65 72 2e 3c 2f me="action">Action.to.trigger.</
4860 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d param>..........///.<param.name=
4880 22 63 6f 6e 74 72 6f 6c 22 3e 43 6f 6e 74 72 6f 6c 20 74 6f 20 62 69 6e 64 20 74 6f 2e 20 54 68 "control">Control.to.bind.to..Th
48a0 65 20 66 75 6c 6c 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 2e 70 e.full.<see.cref="InputControl.p
48c0 61 74 68 22 2f 3e 20 6f 66 20 74 68 65 20 63 6f 6e 74 72 6f 6c 20 77 69 6c 6c 0d 0a 20 20 20 20 ath"/>.of.the.control.will......
48e0 20 20 20 20 2f 2f 2f 20 62 65 20 75 73 65 64 20 69 6e 20 74 68 65 20 72 65 73 75 6c 74 69 6e 67 ....///.be.used.in.the.resulting
4900 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 42 69 6e 64 69 6e 67 22 3e 62 69 6e 64 69 6e .<see.cref="InputBinding">bindin
4920 67 3c 2f 73 65 65 3e 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 72 g</see>.</param>..........///.<r
4940 65 74 75 72 6e 73 3e 53 79 6e 74 61 78 20 74 6f 20 63 6f 6e 66 69 67 75 72 65 20 74 68 65 20 62 eturns>Syntax.to.configure.the.b
4960 69 6e 64 69 6e 67 20 66 75 72 74 68 65 72 2e 3c 2f 72 65 74 75 72 6e 73 3e 0d 0a 20 20 20 20 20 inding.further.</returns>.......
4980 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 41 72 67 75 6d 65 6e 74 ...///.<exception.cref="Argument
49a0 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 61 NullException"><paramref.name="a
49c0 63 74 69 6f 6e 22 2f 3e 20 69 73 20 6e 75 6c 6c 20 6f 72 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 ction"/>.is.null.or.<paramref.na
49e0 6d 65 3d 22 63 6f 6e 74 72 6f 6c 22 2f 3e 20 69 73 20 6e 75 6c 6c 2e 3c 2f 65 78 63 65 70 74 69 me="control"/>.is.null.</excepti
4a00 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c 73 6f 20 63 72 65 66 3d 22 on>..........///.<seealso.cref="
4a20 49 6e 70 75 74 41 63 74 69 6f 6e 2e 62 69 6e 64 69 6e 67 73 22 2f 3e 0d 0a 20 20 20 20 20 20 20 InputAction.bindings"/>.........
4a40 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 41 64 64 .public.static.BindingSyntax.Add
4a60 42 69 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 2c Binding(this.InputAction.action,
4a80 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 20 63 6f 6e 74 72 6f 6c 29 0d 0a 20 20 20 20 20 20 20 20 .InputControl.control)..........
4aa0 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 63 6f 6e 74 72 6f 6c 20 3d 3d 20 6e 75 {..............if.(control.==.nu
4ac0 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 ll)..................throw.new.A
4ae0 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 63 6f 6e 74 rgumentNullException(nameof(cont
4b00 72 6f 6c 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 41 64 64 42 69 rol));..............return.AddBi
4b20 6e 64 69 6e 67 28 61 63 74 69 6f 6e 2c 20 63 6f 6e 74 72 6f 6c 2e 70 61 74 68 29 3b 0d 0a 20 20 nding(action,.control.path);....
4b40 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e ......}............///.<summary>
4b60 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 41 64 64 20 61 20 6e 65 77 20 62 69 6e 64 69 6e 67 20 ..........///.Add.a.new.binding.
4b80 74 6f 20 74 68 65 20 61 63 74 69 6f 6e 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 to.the.action...........///.</su
4ba0 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d mmary>..........///.<param.name=
4bc0 22 61 63 74 69 6f 6e 22 3e 41 6e 20 61 63 74 69 6f 6e 20 74 6f 20 61 64 64 20 74 68 65 20 62 69 "action">An.action.to.add.the.bi
4be0 6e 64 69 6e 67 20 74 6f 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c nding.to.</param>..........///.<
4c00 70 61 72 61 6d 20 6e 61 6d 65 3d 22 62 69 6e 64 69 6e 67 22 3e 42 69 6e 64 69 6e 67 20 74 6f 20 param.name="binding">Binding.to.
4c20 61 64 64 20 74 6f 20 74 68 65 20 61 63 74 69 6f 6e 20 6f 72 20 64 65 66 61 75 6c 74 2e 20 42 69 add.to.the.action.or.default..Bi
4c40 6e 64 69 6e 67 20 63 61 6e 20 62 65 20 66 75 72 74 68 65 72 20 63 6f 6e 66 69 67 75 72 65 64 20 nding.can.be.further.configured.
4c60 76 69 61 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 74 68 65 20 73 74 72 75 63 74 20 72 65 74 75 via..........///.the.struct.retu
4c80 72 6e 65 64 20 62 79 20 74 68 65 20 6d 65 74 68 6f 64 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 rned.by.the.method.</param>.....
4ca0 20 20 20 20 20 2f 2f 2f 20 3c 72 65 74 75 72 6e 73 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 .....///.<returns>..........///.
4cc0 52 65 74 75 72 6e 73 20 61 20 66 6c 75 65 6e 74 2d 73 74 79 6c 65 20 73 79 6e 74 61 78 20 73 74 Returns.a.fluent-style.syntax.st
4ce0 72 75 63 74 75 72 65 20 74 68 61 74 20 61 6c 6c 6f 77 73 20 70 65 72 66 6f 72 6d 69 6e 67 20 61 ructure.that.allows.performing.a
4d00 64 64 69 74 69 6f 6e 61 6c 20 6d 6f 64 69 66 69 63 61 74 69 6f 6e 73 0d 0a 20 20 20 20 20 20 20 dditional.modifications.........
4d20 20 2f 2f 2f 20 62 61 73 65 64 20 6f 6e 20 74 68 65 20 6e 65 77 20 62 69 6e 64 69 6e 67 2e 0d 0a .///.based.on.the.new.binding...
4d40 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 72 65 74 75 72 6e 73 3e 0d 0a 20 20 20 20 20 20 20 20 ........///.</returns>..........
4d60 2f 2f 2f 20 3c 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 54 68 69 73 20 ///.<remarks>..........///.This.
4d80 77 6f 72 6b 73 20 62 6f 74 68 20 77 69 74 68 20 61 63 74 69 6f 6e 73 20 74 68 61 74 20 61 72 65 works.both.with.actions.that.are
4da0 20 70 61 72 74 20 6f 66 20 61 6e 20 61 63 74 69 6f 6e 20 73 65 74 20 61 73 20 77 65 6c 6c 20 61 .part.of.an.action.set.as.well.a
4dc0 73 20 77 69 74 68 20 61 63 74 69 6f 6e 73 20 74 68 61 74 20 61 72 65 6e 27 74 2e 0d 0a 20 20 20 s.with.actions.that.aren't......
4de0 20 20 20 20 20 2f 2f 2f 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 4e 6f 74 65 20 74 68 61 74 20 .....///..........///.Note.that.
4e00 61 63 74 69 6f 6e 73 20 6d 75 73 74 20 62 65 20 64 69 73 61 62 6c 65 64 20 77 68 69 6c 65 20 61 actions.must.be.disabled.while.a
4e20 6c 74 65 72 69 6e 67 20 74 68 65 69 72 20 62 69 6e 64 69 6e 67 20 73 65 74 73 2e 20 41 6c 73 6f ltering.their.binding.sets..Also
4e40 2c 20 69 66 20 74 68 65 20 61 63 74 69 6f 6e 20 62 65 6c 6f 6e 67 73 0d 0a 20 20 20 20 20 20 20 ,.if.the.action.belongs.........
4e60 20 2f 2f 2f 20 74 6f 20 61 20 73 65 74 2c 20 61 6c 6c 20 61 63 74 69 6f 6e 73 20 69 6e 20 74 68 .///.to.a.set,.all.actions.in.th
4e80 65 20 73 65 74 20 6d 75 73 74 20 62 65 20 64 69 73 61 62 6c 65 64 2e 0d 0a 20 20 20 20 20 20 20 e.set.must.be.disabled..........
4ea0 20 2f 2f 2f 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 61 6d 70 6c 65 3e 0d 0a 20 20 20 .///..........///.<example>.....
4ec0 20 20 20 20 20 2f 2f 2f 20 3c 63 6f 64 65 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 66 69 72 .....///.<code>..........///.fir
4ee0 65 41 63 74 69 6f 6e 2e 41 64 64 42 69 6e 64 69 6e 67 28 29 0d 0a 20 20 20 20 20 20 20 20 2f 2f eAction.AddBinding()..........//
4f00 2f 20 20 20 20 20 2e 57 69 74 68 50 61 74 68 28 22 26 6c 74 3b 47 61 6d 65 70 61 64 26 67 74 3b /......WithPath("&lt;Gamepad&gt;
4f20 2f 62 75 74 74 6f 6e 53 6f 75 74 68 22 29 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 20 20 20 20 /buttonSouth")..........///.....
4f40 2e 57 69 74 68 47 72 6f 75 70 28 22 47 61 6d 65 70 61 64 22 29 3b 0d 0a 20 20 20 20 20 20 20 20 .WithGroup("Gamepad");..........
4f60 2f 2f 2f 20 3c 2f 63 6f 64 65 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 65 78 61 6d 70 ///.</code>..........///.</examp
4f80 6c 65 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 le>..........///.</remarks>.....
4fa0 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 .....public.static.BindingSyntax
4fc0 20 41 64 64 42 69 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 .AddBinding(this.InputAction.act
4fe0 69 6f 6e 2c 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 62 69 6e 64 69 6e 67 20 3d 20 64 65 66 61 ion,.InputBinding.binding.=.defa
5000 75 6c 74 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 ult)..........{..............if.
5020 28 61 63 74 69 6f 6e 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 (action.==.null)................
5040 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f ..throw.new.ArgumentNullExceptio
5060 6e 28 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 n(nameof(action));..............
5080 20 20 2f 2f 2f 2f 52 45 56 49 45 57 3a 20 73 68 6f 75 6c 64 20 74 68 69 73 20 72 65 66 65 72 65 ..////REVIEW:.should.this.refere
50a0 6e 63 65 20 61 63 74 69 6f 6e 73 20 62 79 20 49 44 3f 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 nce.actions.by.ID?..............
50c0 44 65 62 75 67 2e 41 73 73 65 72 74 28 61 63 74 69 6f 6e 2e 6d 5f 4e 61 6d 65 20 21 3d 20 6e 75 Debug.Assert(action.m_Name.!=.nu
50e0 6c 6c 20 7c 7c 20 61 63 74 69 6f 6e 2e 69 73 53 69 6e 67 6c 65 74 6f 6e 41 63 74 69 6f 6e 29 3b ll.||.action.isSingletonAction);
5100 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 62 69 6e 64 69 6e 67 2e 61 63 74 69 6f 6e 20 3d 20 61 ..............binding.action.=.a
5120 63 74 69 6f 6e 2e 6e 61 6d 65 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 61 ction.name;................var.a
5140 63 74 69 6f 6e 4d 61 70 20 3d 20 61 63 74 69 6f 6e 2e 47 65 74 4f 72 43 72 65 61 74 65 41 63 74 ctionMap.=.action.GetOrCreateAct
5160 69 6f 6e 4d 61 70 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 69 ionMap();..............var.bindi
5180 6e 67 49 6e 64 65 78 20 3d 20 41 64 64 42 69 6e 64 69 6e 67 49 6e 74 65 72 6e 61 6c 28 61 63 74 ngIndex.=.AddBindingInternal(act
51a0 69 6f 6e 4d 61 70 2c 20 62 69 6e 64 69 6e 67 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 ionMap,.binding);..............r
51c0 65 74 75 72 6e 20 6e 65 77 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 28 61 63 74 69 6f 6e 4d 61 eturn.new.BindingSyntax(actionMa
51e0 70 2c 20 61 63 74 69 6f 6e 2c 20 62 69 6e 64 69 6e 67 49 6e 64 65 78 29 3b 0d 0a 20 20 20 20 20 p,.action,.bindingIndex);.......
5200 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 42 69 ...}............public.static.Bi
5220 6e 64 69 6e 67 53 79 6e 74 61 78 20 41 64 64 42 69 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 ndingSyntax.AddBinding(this.Inpu
5240 74 41 63 74 69 6f 6e 4d 61 70 20 61 63 74 69 6f 6e 4d 61 70 2c 20 73 74 72 69 6e 67 20 70 61 74 tActionMap.actionMap,.string.pat
5260 68 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 74 72 69 6e 67 20 69 6e 74 65 72 61 63 74 69 h,..............string.interacti
5280 6f 6e 73 20 3d 20 6e 75 6c 6c 2c 20 73 74 72 69 6e 67 20 67 72 6f 75 70 73 20 3d 20 6e 75 6c 6c ons.=.null,.string.groups.=.null
52a0 2c 20 73 74 72 69 6e 67 20 61 63 74 69 6f 6e 20 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 ,.string.action.=.null).........
52c0 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 70 61 74 68 20 3d 3d 20 6e 75 6c 6c .{..............if.(path.==.null
52e0 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 )..................throw.new.Arg
5300 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 22 42 69 6e 64 69 6e 67 20 70 61 74 68 20 63 61 6e umentException("Binding.path.can
5320 6e 6f 74 20 62 65 20 6e 75 6c 6c 22 2c 20 6e 61 6d 65 6f 66 28 70 61 74 68 29 29 3b 0d 0a 0d 0a not.be.null",.nameof(path));....
5340 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 41 64 64 42 69 6e 64 69 6e 67 28 61 63 ............return.AddBinding(ac
5360 74 69 6f 6e 4d 61 70 2c 20 6e 65 77 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 0d 0a 20 20 20 20 20 tionMap,.new.InputBinding.......
5380 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 70 61 74 68 20 3d .......{..................path.=
53a0 20 70 61 74 68 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 74 65 72 61 63 74 .path,..................interact
53c0 69 6f 6e 73 20 3d 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 ions.=.interactions,............
53e0 20 20 20 20 20 20 67 72 6f 75 70 73 20 3d 20 67 72 6f 75 70 73 2c 0d 0a 20 20 20 20 20 20 20 20 ......groups.=.groups,..........
5400 20 20 20 20 20 20 20 20 61 63 74 69 6f 6e 20 3d 20 61 63 74 69 6f 6e 0d 0a 20 20 20 20 20 20 20 ........action.=.action.........
5420 20 20 20 20 20 7d 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 .....});..........}............p
5440 75 62 6c 69 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 41 64 64 42 69 ublic.static.BindingSyntax.AddBi
5460 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 70 20 61 63 74 69 6f 6e nding(this.InputActionMap.action
5480 4d 61 70 2c 20 73 74 72 69 6e 67 20 70 61 74 68 2c 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 Map,.string.path,.InputAction.ac
54a0 74 69 6f 6e 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 74 72 69 6e 67 20 69 6e 74 65 72 61 tion,..............string.intera
54c0 63 74 69 6f 6e 73 20 3d 20 6e 75 6c 6c 2c 20 73 74 72 69 6e 67 20 67 72 6f 75 70 73 20 3d 20 6e ctions.=.null,.string.groups.=.n
54e0 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 ull)..........{..............if.
5500 28 61 63 74 69 6f 6e 20 21 3d 20 6e 75 6c 6c 20 26 26 20 61 63 74 69 6f 6e 2e 61 63 74 69 6f 6e (action.!=.null.&&.action.action
5520 4d 61 70 20 21 3d 20 61 63 74 69 6f 6e 4d 61 70 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 Map.!=.actionMap)...............
5540 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 0d ...throw.new.ArgumentException(.
5560 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 22 41 63 74 69 6f 6e 20 27 7b .....................$"Action.'{
5580 61 63 74 69 6f 6e 7d 27 20 69 73 20 6e 6f 74 20 70 61 72 74 20 6f 66 20 61 63 74 69 6f 6e 20 6d action}'.is.not.part.of.action.m
55a0 61 70 20 27 7b 61 63 74 69 6f 6e 4d 61 70 7d 27 22 2c 20 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e ap.'{actionMap}'",.nameof(action
55c0 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 20 3d 3d ));................if.(action.==
55e0 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 41 .null)..................return.A
5600 64 64 42 69 6e 64 69 6e 67 28 61 63 74 69 6f 6e 4d 61 70 2c 20 70 61 74 68 3a 20 70 61 74 68 2c ddBinding(actionMap,.path:.path,
5620 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 3a 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 2c 20 67 72 6f .interactions:.interactions,.gro
5640 75 70 73 3a 20 67 72 6f 75 70 73 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 ups:.groups);................ret
5660 75 72 6e 20 41 64 64 42 69 6e 64 69 6e 67 28 61 63 74 69 6f 6e 4d 61 70 2c 20 70 61 74 68 3a 20 urn.AddBinding(actionMap,.path:.
5680 70 61 74 68 2c 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 3a 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 path,.interactions:.interactions
56a0 2c 20 67 72 6f 75 70 73 3a 20 67 72 6f 75 70 73 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 ,.groups:.groups,...............
56c0 20 20 20 61 63 74 69 6f 6e 3a 20 61 63 74 69 6f 6e 2e 69 64 29 3b 0d 0a 20 20 20 20 20 20 20 20 ...action:.action.id);..........
56e0 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 }............public.static.Bindi
5700 6e 67 53 79 6e 74 61 78 20 41 64 64 42 69 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 74 41 63 ngSyntax.AddBinding(this.InputAc
5720 74 69 6f 6e 4d 61 70 20 61 63 74 69 6f 6e 4d 61 70 2c 20 73 74 72 69 6e 67 20 70 61 74 68 2c 20 tionMap.actionMap,.string.path,.
5740 47 75 69 64 20 61 63 74 69 6f 6e 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 73 74 72 69 6e 67 Guid.action,..............string
5760 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 20 3d 20 6e 75 6c 6c 2c 20 73 74 72 69 6e 67 20 67 72 6f .interactions.=.null,.string.gro
5780 75 70 73 20 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 ups.=.null)..........{..........
57a0 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 20 3d 3d 20 47 75 69 64 2e 45 6d 70 74 79 29 0d 0a 20 ....if.(action.==.Guid.Empty)...
57c0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 41 64 64 42 69 6e 64 69 6e 67 ...............return.AddBinding
57e0 28 61 63 74 69 6f 6e 4d 61 70 2c 20 70 61 74 68 3a 20 70 61 74 68 2c 20 69 6e 74 65 72 61 63 74 (actionMap,.path:.path,.interact
5800 69 6f 6e 73 3a 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 2c 20 67 72 6f 75 70 73 3a 20 67 72 6f 75 ions:.interactions,.groups:.grou
5820 70 73 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 41 64 64 42 69 6e 64 ps);..............return.AddBind
5840 69 6e 67 28 61 63 74 69 6f 6e 4d 61 70 2c 20 70 61 74 68 3a 20 70 61 74 68 2c 20 69 6e 74 65 72 ing(actionMap,.path:.path,.inter
5860 61 63 74 69 6f 6e 73 3a 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 2c 20 67 72 6f 75 70 73 3a 20 67 actions:.interactions,.groups:.g
5880 72 6f 75 70 73 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 61 63 74 69 6f 6e 3a 20 roups,..................action:.
58a0 61 63 74 69 6f 6e 2e 54 6f 53 74 72 69 6e 67 28 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a action.ToString());..........}..
58c0 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 ..........public.static.BindingS
58e0 79 6e 74 61 78 20 41 64 64 42 69 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f yntax.AddBinding(this.InputActio
5900 6e 4d 61 70 20 61 63 74 69 6f 6e 4d 61 70 2c 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 62 69 6e nMap.actionMap,.InputBinding.bin
5920 64 69 6e 67 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 ding)..........{..............if
5940 20 28 61 63 74 69 6f 6e 4d 61 70 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 .(actionMap.==.null)............
5960 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 ......throw.new.ArgumentNullExce
5980 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e 4d 61 70 29 29 3b 0d 0a 20 20 20 20 20 ption(nameof(actionMap));.......
59a0 20 20 20 20 20 20 20 69 66 20 28 62 69 6e 64 69 6e 67 2e 70 61 74 68 20 3d 3d 20 6e 75 6c 6c 29 .......if.(binding.path.==.null)
59c0 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 ..................throw.new.Argu
59e0 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 22 42 69 6e 64 69 6e 67 20 70 61 74 68 20 63 61 6e 6e mentException("Binding.path.cann
5a00 6f 74 20 62 65 20 6e 75 6c 6c 22 2c 20 6e 61 6d 65 6f 66 28 62 69 6e 64 69 6e 67 29 29 3b 0d 0a ot.be.null",.nameof(binding));..
5a20 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 69 6e 67 49 6e 64 65 78 20 3d ..............var.bindingIndex.=
5a40 20 41 64 64 42 69 6e 64 69 6e 67 49 6e 74 65 72 6e 61 6c 28 61 63 74 69 6f 6e 4d 61 70 2c 20 62 .AddBindingInternal(actionMap,.b
5a60 69 6e 64 69 6e 67 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 inding);..............return.new
5a80 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 28 61 63 74 69 6f 6e 4d 61 70 2c 20 6e 75 6c 6c 2c 20 .BindingSyntax(actionMap,.null,.
5aa0 62 69 6e 64 69 6e 67 49 6e 64 65 78 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 bindingIndex);..........}.......
5ac0 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 43 6f 6d 70 6f 73 69 74 65 53 79 6e 74 .....public.static.CompositeSynt
5ae0 61 78 20 41 64 64 43 6f 6d 70 6f 73 69 74 65 42 69 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 ax.AddCompositeBinding(this.Inpu
5b00 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 2c 20 73 74 72 69 6e 67 20 63 6f 6d 70 6f 73 69 74 65 tAction.action,.string.composite
5b20 2c 20 73 74 72 69 6e 67 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 20 3d 20 6e 75 6c 6c 2c 20 73 74 ,.string.interactions.=.null,.st
5b40 72 69 6e 67 20 70 72 6f 63 65 73 73 6f 72 73 20 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 ring.processors.=.null).........
5b60 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 20 3d 3d 20 6e 75 .{..............if.(action.==.nu
5b80 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 ll)..................throw.new.A
5ba0 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 63 74 69 rgumentNullException(nameof(acti
5bc0 6f 6e 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 on));..............if.(string.Is
5be0 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 63 6f 6d 70 6f 73 69 74 65 29 29 0d 0a 20 20 20 20 20 20 20 NullOrEmpty(composite)).........
5c00 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 45 78 63 65 70 .........throw.new.ArgumentExcep
5c20 74 69 6f 6e 28 22 43 6f 6d 70 6f 73 69 74 65 20 6e 61 6d 65 20 63 61 6e 6e 6f 74 20 62 65 20 6e tion("Composite.name.cannot.be.n
5c40 75 6c 6c 20 6f 72 20 65 6d 70 74 79 22 2c 20 6e 61 6d 65 6f 66 28 63 6f 6d 70 6f 73 69 74 65 29 ull.or.empty",.nameof(composite)
5c60 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 61 63 74 69 6f 6e 4d 61 70 20 );................var.actionMap.
5c80 3d 20 61 63 74 69 6f 6e 2e 47 65 74 4f 72 43 72 65 61 74 65 41 63 74 69 6f 6e 4d 61 70 28 29 3b =.action.GetOrCreateActionMap();
5ca0 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 2f 52 45 56 49 45 57 3a 20 75 73 65 20 ................////REVIEW:.use.
5cc0 27 6e 61 6d 65 27 20 69 6e 73 74 65 61 64 20 6f 66 20 27 70 61 74 68 27 20 66 69 65 6c 64 20 68 'name'.instead.of.'path'.field.h
5ce0 65 72 65 3f 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 69 6e 67 20 3d 20 ere?..............var.binding.=.
5d00 6e 65 77 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 7b 70 61 74 68 20 3d 20 63 6f 6d 70 6f 73 69 new.InputBinding.{path.=.composi
5d20 74 65 2c 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 20 3d 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 2c te,.interactions.=.interactions,
5d40 20 70 72 6f 63 65 73 73 6f 72 73 20 3d 20 70 72 6f 63 65 73 73 6f 72 73 2c 20 69 73 43 6f 6d 70 .processors.=.processors,.isComp
5d60 6f 73 69 74 65 20 3d 20 74 72 75 65 2c 20 61 63 74 69 6f 6e 20 3d 20 61 63 74 69 6f 6e 2e 6e 61 osite.=.true,.action.=.action.na
5d80 6d 65 7d 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 69 6e 67 49 6e 64 me};..............var.bindingInd
5da0 65 78 20 3d 20 41 64 64 42 69 6e 64 69 6e 67 49 6e 74 65 72 6e 61 6c 28 61 63 74 69 6f 6e 4d 61 ex.=.AddBindingInternal(actionMa
5dc0 70 2c 20 62 69 6e 64 69 6e 67 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e p,.binding);..............return
5de0 20 6e 65 77 20 43 6f 6d 70 6f 73 69 74 65 53 79 6e 74 61 78 28 61 63 74 69 6f 6e 4d 61 70 2c 20 .new.CompositeSyntax(actionMap,.
5e00 61 63 74 69 6f 6e 2c 20 62 69 6e 64 69 6e 67 49 6e 64 65 78 29 3b 0d 0a 20 20 20 20 20 20 20 20 action,.bindingIndex);..........
5e20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 72 69 76 61 74 65 20 73 74 61 74 69 63 20 69 6e 74 20 }............private.static.int.
5e40 41 64 64 42 69 6e 64 69 6e 67 49 6e 74 65 72 6e 61 6c 28 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 AddBindingInternal(InputActionMa
5e60 70 20 6d 61 70 2c 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 62 69 6e 64 69 6e 67 29 0d 0a 20 20 p.map,.InputBinding.binding)....
5e80 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 44 65 62 75 67 2e 41 73 73 65 72 ......{..............Debug.Asser
5ea0 74 28 6d 61 70 20 21 3d 20 6e 75 6c 6c 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f t(map.!=.null);................/
5ec0 2f 20 4d 61 6b 65 20 73 75 72 65 20 74 68 65 20 62 69 6e 64 69 6e 67 20 68 61 73 20 61 6e 20 49 /.Make.sure.the.binding.has.an.I
5ee0 44 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c D...............if.(string.IsNul
5f00 6c 4f 72 45 6d 70 74 79 28 62 69 6e 64 69 6e 67 2e 6d 5f 49 64 29 29 0d 0a 20 20 20 20 20 20 20 lOrEmpty(binding.m_Id)).........
5f20 20 20 20 20 20 20 20 20 20 62 69 6e 64 69 6e 67 2e 47 65 6e 65 72 61 74 65 49 64 28 29 3b 0d 0a .........binding.GenerateId();..
5f40 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 41 70 70 65 6e 64 20 74 6f 20 62 69 6e 64 69 ..............//.Append.to.bindi
5f60 6e 67 73 20 69 6e 20 73 65 74 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e ngs.in.set...............var.bin
5f80 64 69 6e 67 49 6e 64 65 78 20 3d 20 41 72 72 61 79 48 65 6c 70 65 72 73 2e 41 70 70 65 6e 64 28 dingIndex.=.ArrayHelpers.Append(
5fa0 72 65 66 20 6d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 2c 20 62 69 6e 64 69 6e 67 29 3b 0d 0a 0d ref.map.m_Bindings,.binding);...
5fc0 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 49 6e 76 61 6c 69 64 61 74 65 20 70 65 72 2d 61 .............//.Invalidate.per-a
5fe0 63 74 69 6f 6e 20 62 69 6e 64 69 6e 67 20 73 65 74 73 20 73 6f 20 74 68 61 74 20 74 68 69 73 20 ction.binding.sets.so.that.this.
6000 67 65 74 73 20 72 65 66 72 65 73 68 65 64 20 69 66 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f gets.refreshed.if............../
6020 2f 20 61 6e 79 6f 6e 65 20 71 75 65 72 69 65 73 20 69 74 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 /.anyone.queries.it.............
6040 20 20 6d 61 70 2e 43 6c 65 61 72 50 65 72 41 63 74 69 6f 6e 43 61 63 68 65 64 42 69 6e 64 69 6e ..map.ClearPerActionCachedBindin
6060 67 44 61 74 61 28 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4d 61 6b 65 20 gData();................//.Make.
6080 73 75 72 65 20 62 69 6e 64 69 6e 67 73 20 67 65 74 20 72 65 2d 72 65 73 6f 6c 76 65 64 2e 0d 0a sure.bindings.get.re-resolved...
60a0 20 20 20 20 20 20 20 20 20 20 20 20 6d 61 70 2e 4c 61 7a 79 52 65 73 6f 6c 76 65 42 69 6e 64 69 ............map.LazyResolveBindi
60c0 6e 67 73 28 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 49 66 20 77 65 27 72 ngs();................//.If.we'r
60e0 65 20 6c 6f 6f 6b 69 6e 67 20 61 74 20 61 20 73 69 6e 67 6c 65 74 6f 6e 20 61 63 74 69 6f 6e 2c e.looking.at.a.singleton.action,
6100 20 6d 61 6b 65 20 73 75 72 65 20 6d 5f 42 69 6e 64 69 6e 67 73 20 69 73 20 75 70 20 74 6f 20 64 .make.sure.m_Bindings.is.up.to.d
6120 61 74 65 20 6a 75 73 74 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 69 6e 20 63 61 73 65 ate.just..............//.in.case
6140 20 74 68 65 20 61 63 74 69 6f 6e 20 67 65 74 73 20 73 65 72 69 61 6c 69 7a 65 64 2e 0d 0a 20 20 .the.action.gets.serialized.....
6160 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 61 70 2e 6d 5f 53 69 6e 67 6c 65 74 6f 6e 41 63 74 ..........if.(map.m_SingletonAct
6180 69 6f 6e 20 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 61 ion.!=.null)..................ma
61a0 70 2e 6d 5f 53 69 6e 67 6c 65 74 6f 6e 41 63 74 69 6f 6e 2e 6d 5f 53 69 6e 67 6c 65 74 6f 6e 41 p.m_SingletonAction.m_SingletonA
61c0 63 74 69 6f 6e 42 69 6e 64 69 6e 67 73 20 3d 20 6d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 3b 0d ctionBindings.=.map.m_Bindings;.
61e0 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 62 69 6e 64 69 6e 67 49 6e 64 ...............return.bindingInd
6200 65 78 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 ex;..........}............public
6220 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 43 68 61 6e 67 65 42 69 6e 64 .static.BindingSyntax.ChangeBind
6240 69 6e 67 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 2c 20 69 6e 74 ing(this.InputAction.action,.int
6260 20 69 6e 64 65 78 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 .index)..........{..............
6280 69 66 20 28 61 63 74 69 6f 6e 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 if.(action.==.null).............
62a0 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 .....throw.new.ArgumentNullExcep
62c0 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 tion(nameof(action));...........
62e0 20 20 20 20 20 76 61 72 20 69 6e 64 65 78 4f 6e 4d 61 70 20 3d 20 61 63 74 69 6f 6e 2e 42 69 6e .....var.indexOnMap.=.action.Bin
6300 64 69 6e 67 49 6e 64 65 78 4f 6e 41 63 74 69 6f 6e 54 6f 42 69 6e 64 69 6e 67 49 6e 64 65 78 4f dingIndexOnActionToBindingIndexO
6320 6e 4d 61 70 28 69 6e 64 65 78 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e nMap(index);..............return
6340 20 6e 65 77 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 28 61 63 74 69 6f 6e 2e 47 65 74 4f 72 43 .new.BindingSyntax(action.GetOrC
6360 72 65 61 74 65 41 63 74 69 6f 6e 4d 61 70 28 29 2c 20 61 63 74 69 6f 6e 2c 20 69 6e 64 65 78 4f reateActionMap(),.action,.indexO
6380 6e 4d 61 70 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 nMap);..........}............pub
63a0 6c 69 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 43 68 61 6e 67 65 42 lic.static.BindingSyntax.ChangeB
63c0 69 6e 64 69 6e 67 57 69 74 68 49 64 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 indingWithId(this.InputAction.ac
63e0 74 69 6f 6e 2c 20 73 74 72 69 6e 67 20 69 64 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 tion,.string.id)..........{.....
6400 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 63 74 69 6f 6e 2e 43 68 61 6e 67 65 42 69 6e .........return.action.ChangeBin
6420 64 69 6e 67 28 6e 65 77 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 7b 6d 5f 49 64 20 3d 20 69 64 ding(new.InputBinding.{m_Id.=.id
6440 7d 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 });..........}............public
6460 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 43 68 61 6e 67 65 42 69 6e 64 .static.BindingSyntax.ChangeBind
6480 69 6e 67 57 69 74 68 49 64 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f ingWithId(this.InputAction.actio
64a0 6e 2c 20 47 75 69 64 20 69 64 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 n,.Guid.id)..........{..........
64c0 20 20 20 20 72 65 74 75 72 6e 20 61 63 74 69 6f 6e 2e 43 68 61 6e 67 65 42 69 6e 64 69 6e 67 28 ....return.action.ChangeBinding(
64e0 6e 65 77 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 7b 69 64 20 3d 20 69 64 7d 29 3b 0d 0a 20 20 new.InputBinding.{id.=.id});....
6500 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 ......}............public.static
6520 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 43 68 61 6e 67 65 42 69 6e 64 69 6e 67 57 69 74 68 .BindingSyntax.ChangeBindingWith
6540 47 72 6f 75 70 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 2c 20 73 Group(this.InputAction.action,.s
6560 74 72 69 6e 67 20 67 72 6f 75 70 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 tring.group)..........{.........
6580 20 20 20 20 20 72 65 74 75 72 6e 20 61 63 74 69 6f 6e 2e 43 68 61 6e 67 65 42 69 6e 64 69 6e 67 .....return.action.ChangeBinding
65a0 28 6e 65 77 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 7b 67 72 6f 75 70 73 20 3d 20 67 72 6f 75 (new.InputBinding.{groups.=.grou
65c0 70 7d 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 p});..........}............publi
65e0 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 43 68 61 6e 67 65 42 69 6e c.static.BindingSyntax.ChangeBin
6600 64 69 6e 67 57 69 74 68 50 61 74 68 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 dingWithPath(this.InputAction.ac
6620 74 69 6f 6e 2c 20 73 74 72 69 6e 67 20 70 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 tion,.string.path)..........{...
6640 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 61 63 74 69 6f 6e 2e 43 68 61 6e 67 65 42 ...........return.action.ChangeB
6660 69 6e 64 69 6e 67 28 6e 65 77 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 7b 70 61 74 68 20 3d 20 inding(new.InputBinding.{path.=.
6680 70 61 74 68 7d 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 path});..........}............pu
66a0 62 6c 69 63 20 73 74 61 74 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 43 68 61 6e 67 65 blic.static.BindingSyntax.Change
66c0 42 69 6e 64 69 6e 67 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 2c Binding(this.InputAction.action,
66e0 20 49 6e 70 75 74 42 69 6e 64 69 6e 67 20 6d 61 74 63 68 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d .InputBinding.match)..........{.
6700 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 20 3d 3d 20 6e 75 6c 6c 29 .............if.(action.==.null)
6720 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 ..................throw.new.Argu
6740 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e 29 mentNullException(nameof(action)
6760 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 61 63 74 69 6f 6e 4d 61 70 20 );................var.actionMap.
6780 3d 20 61 63 74 69 6f 6e 2e 47 65 74 4f 72 43 72 65 61 74 65 41 63 74 69 6f 6e 4d 61 70 28 29 3b =.action.GetOrCreateActionMap();
67a0 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 69 6e 67 49 6e 64 65 78 20 3d ..............var.bindingIndex.=
67c0 20 61 63 74 69 6f 6e 4d 61 70 2e 46 69 6e 64 42 69 6e 64 69 6e 67 28 6d 61 74 63 68 29 3b 0d 0a .actionMap.FindBinding(match);..
67e0 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 62 69 6e 64 69 6e 67 49 6e 64 65 78 20 3d 3d 20 ............if.(bindingIndex.==.
6800 2d 31 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 -1)..................throw.new.A
6820 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 24 22 43 61 6e 6e 6f 74 20 66 69 6e 64 20 62 rgumentException($"Cannot.find.b
6840 69 6e 64 69 6e 67 20 6d 61 74 63 68 69 6e 67 20 27 7b 6d 61 74 63 68 7d 27 20 69 6e 20 27 7b 61 inding.matching.'{match}'.in.'{a
6860 63 74 69 6f 6e 7d 27 22 2c 20 6e 61 6d 65 6f 66 28 6d 61 74 63 68 29 29 3b 0d 0a 0d 0a 20 20 20 ction}'",.nameof(match));.......
6880 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 .........return.new.BindingSynta
68a0 78 28 61 63 74 69 6f 6e 4d 61 70 2c 20 61 63 74 69 6f 6e 2c 20 62 69 6e 64 69 6e 67 49 6e 64 65 x(actionMap,.action,.bindingInde
68c0 78 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 2f 54 4f x);..........}............////TO
68e0 44 4f 3a 20 75 70 64 61 74 65 20 62 69 6e 64 69 6e 67 20 6d 61 73 6b 20 69 66 20 6e 65 63 65 73 DO:.update.binding.mask.if.neces
6900 73 61 72 79 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 sary..........///.<summary>.....
6920 20 20 20 20 20 2f 2f 2f 20 52 65 6e 61 6d 65 20 61 6e 20 65 78 69 73 74 69 6e 67 20 61 63 74 69 .....///.Rename.an.existing.acti
6940 6f 6e 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 on...........///.</summary>.....
6960 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 61 63 74 69 6f 6e 22 3e 41 63 .....///.<param.name="action">Ac
6980 74 69 6f 6e 20 74 6f 20 61 73 73 69 67 6e 20 61 20 6e 65 77 20 6e 61 6d 65 20 74 6f 2e 20 43 61 tion.to.assign.a.new.name.to..Ca
69a0 6e 20 62 65 20 73 69 6e 67 6c 65 74 6f 6e 20 61 63 74 69 6f 6e 20 6f 72 20 61 63 74 69 6f 6e 20 n.be.singleton.action.or.action.
69c0 74 68 61 74 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 69 73 20 70 61 72 74 20 6f 66 20 61 20 6d that..........///.is.part.of.a.m
69e0 61 70 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 ap.</param>..........///.<param.
6a00 6e 61 6d 65 3d 22 6e 65 77 4e 61 6d 65 22 3e 4e 65 77 20 6e 61 6d 65 20 74 6f 20 61 73 73 69 67 name="newName">New.name.to.assig
6a20 6e 20 74 6f 20 61 63 74 69 6f 6e 2e 20 43 61 6e 6e 6f 74 20 62 65 20 65 6d 70 74 79 2e 3c 2f 70 n.to.action..Cannot.be.empty.</p
6a40 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 aram>..........///.<exception.cr
6a60 65 66 3d 22 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 ef="ArgumentNullException"><para
6a80 6d 72 65 66 20 6e 61 6d 65 3d 22 61 63 74 69 6f 6e 22 2f 3e 20 69 73 20 6e 75 6c 6c 20 6f 72 20 mref.name="action"/>.is.null.or.
6aa0 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6e 65 77 4e 61 6d 65 22 2f 3e 20 69 73 0d 0a 20 <paramref.name="newName"/>.is...
6ac0 20 20 20 20 20 20 20 2f 2f 2f 20 6e 75 6c 6c 20 6f 72 20 65 6d 70 74 79 2e 3c 2f 65 78 63 65 70 .......///.null.or.empty.</excep
6ae0 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 tion>..........///.<exception.cr
6b00 65 66 3d 22 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 22 3e 3c ef="InvalidOperationException"><
6b20 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 2e 61 63 74 69 6f 6e 4d 61 70 22 see.cref="InputAction.actionMap"
6b40 2f 3e 20 6f 66 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 61 63 74 69 6f 6e 22 2f 3e 0d />.of.<paramref.name="action"/>.
6b60 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 61 6c 72 65 61 64 79 20 63 6f 6e 74 61 69 6e 73 20 61 6e .........///.already.contains.an
6b80 20 61 63 74 69 6f 6e 20 63 61 6c 6c 65 64 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6e .action.called.<paramref.name="n
6ba0 65 77 4e 61 6d 65 22 2f 3e 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 ewName"/>.</exception>..........
6bc0 2f 2f 2f 20 3c 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 52 65 6e 61 6d ///.<remarks>..........///.Renam
6be0 69 6e 67 20 61 6e 20 61 63 74 69 6f 6e 20 77 69 6c 6c 20 61 6c 73 6f 20 75 70 64 61 74 65 20 74 ing.an.action.will.also.update.t
6c00 68 65 20 62 69 6e 64 69 6e 67 73 20 74 68 61 74 20 72 65 66 65 72 20 74 6f 20 74 68 65 20 61 63 he.bindings.that.refer.to.the.ac
6c20 74 69 6f 6e 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 72 65 6d 61 72 6b 73 3e 0d 0a 20 tion...........///.</remarks>...
6c40 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 76 6f 69 64 20 52 65 6e 61 6d 65 .......public.static.void.Rename
6c60 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 2c 20 73 74 72 69 6e 67 (this.InputAction.action,.string
6c80 20 6e 65 77 4e 61 6d 65 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 .newName)..........{............
6ca0 20 20 69 66 20 28 61 63 74 69 6f 6e 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 ..if.(action.==.null)...........
6cc0 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 .......throw.new.ArgumentNullExc
6ce0 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e 29 29 3b 0d 0a 20 20 20 20 20 20 20 eption(nameof(action));.........
6d00 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 6e 65 .....if.(string.IsNullOrEmpty(ne
6d20 77 4e 61 6d 65 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e wName))..................throw.n
6d40 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 ew.ArgumentNullException(nameof(
6d60 6e 65 77 4e 61 6d 65 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 newName));................if.(ac
6d80 74 69 6f 6e 2e 6e 61 6d 65 20 3d 3d 20 6e 65 77 4e 61 6d 65 29 0d 0a 20 20 20 20 20 20 20 20 20 tion.name.==.newName)...........
6da0 20 20 20 20 20 20 20 72 65 74 75 72 6e 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f .......return;................//
6dc0 20 4d 61 6b 65 20 73 75 72 65 20 6e 61 6d 65 20 69 73 6e 27 74 20 61 6c 72 65 61 64 79 20 74 61 .Make.sure.name.isn't.already.ta
6de0 6b 65 6e 20 69 6e 20 6d 61 70 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 61 63 74 ken.in.map...............var.act
6e00 69 6f 6e 4d 61 70 20 3d 20 61 63 74 69 6f 6e 2e 61 63 74 69 6f 6e 4d 61 70 3b 0d 0a 20 20 20 20 ionMap.=.action.actionMap;......
6e20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 4d 61 70 3f 2e 46 69 6e 64 41 63 74 69 6f ........if.(actionMap?.FindActio
6e40 6e 28 6e 65 77 4e 61 6d 65 29 20 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 n(newName).!=.null).............
6e60 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 .....throw.new.InvalidOperationE
6e80 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 xception(......................$
6ea0 22 43 61 6e 6e 6f 74 20 72 65 6e 61 6d 65 20 27 7b 61 63 74 69 6f 6e 7d 27 20 74 6f 20 27 7b 6e "Cannot.rename.'{action}'.to.'{n
6ec0 65 77 4e 61 6d 65 7d 27 20 69 6e 20 6d 61 70 20 27 7b 61 63 74 69 6f 6e 4d 61 70 7d 27 20 61 73 ewName}'.in.map.'{actionMap}'.as
6ee0 20 74 68 65 20 6d 61 70 20 61 6c 72 65 61 64 79 20 63 6f 6e 74 61 69 6e 73 20 61 6e 20 61 63 74 .the.map.already.contains.an.act
6f00 69 6f 6e 20 77 69 74 68 20 74 68 61 74 20 6e 61 6d 65 22 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 ion.with.that.name");...........
6f20 20 20 20 20 20 76 61 72 20 6f 6c 64 4e 61 6d 65 20 3d 20 61 63 74 69 6f 6e 2e 6d 5f 4e 61 6d 65 .....var.oldName.=.action.m_Name
6f40 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 63 74 69 6f 6e 2e 6d 5f 4e 61 6d 65 20 3d 20 6e ;..............action.m_Name.=.n
6f60 65 77 4e 61 6d 65 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 55 70 64 61 74 65 ewName;................//.Update
6f80 20 62 69 6e 64 69 6e 67 73 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 62 69 6e 64 .bindings...............var.bind
6fa0 69 6e 67 73 20 3d 20 61 63 74 69 6f 6e 2e 47 65 74 4f 72 43 72 65 61 74 65 41 63 74 69 6f 6e 4d ings.=.action.GetOrCreateActionM
6fc0 61 70 28 29 2e 6d 5f 42 69 6e 64 69 6e 67 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 ap().m_Bindings;..............va
6fe0 72 20 62 69 6e 64 69 6e 67 43 6f 75 6e 74 20 3d 20 62 69 6e 64 69 6e 67 73 2e 4c 65 6e 67 74 68 r.bindingCount.=.bindings.Length
7000 53 61 66 65 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 66 6f 72 20 28 76 61 72 20 69 20 Safe();..............for.(var.i.
7020 3d 20 30 3b 20 69 20 3c 20 62 69 6e 64 69 6e 67 43 6f 75 6e 74 3b 20 2b 2b 69 29 0d 0a 20 20 20 =.0;.i.<.bindingCount;.++i).....
7040 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 43 6f 6d 70 61 72 65 28 .............if.(string.Compare(
7060 62 69 6e 64 69 6e 67 73 5b 69 5d 2e 61 63 74 69 6f 6e 2c 20 6f 6c 64 4e 61 6d 65 2c 20 53 74 72 bindings[i].action,.oldName,.Str
7080 69 6e 67 43 6f 6d 70 61 72 69 73 6f 6e 2e 49 6e 76 61 72 69 61 6e 74 43 75 6c 74 75 72 65 49 67 ingComparison.InvariantCultureIg
70a0 6e 6f 72 65 43 61 73 65 29 20 3d 3d 20 30 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 noreCase).==.0).................
70c0 20 20 20 20 20 62 69 6e 64 69 6e 67 73 5b 69 5d 2e 61 63 74 69 6f 6e 20 3d 20 6e 65 77 4e 61 6d .....bindings[i].action.=.newNam
70e0 65 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 e;..........}............///.<su
7100 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 41 64 64 20 61 20 6e 65 77 20 63 6f mmary>..........///.Add.a.new.co
7120 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 74 6f 20 74 68 65 20 61 73 73 65 74 2e 0d 0a 20 20 20 20 ntrol.scheme.to.the.asset.......
7140 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 ....///.</summary>..........///.
7160 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 3e 41 73 73 65 74 20 74 6f 20 61 64 64 <param.name="asset">Asset.to.add
7180 20 74 68 65 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 74 6f 2e 3c 2f 70 61 72 61 6d 3e 0d .the.control.scheme.to.</param>.
71a0 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 63 6f 6e 74 72 6f .........///.<param.name="contro
71c0 6c 53 63 68 65 6d 65 22 3e 43 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 74 6f 20 61 64 64 2e 3c lScheme">Control.scheme.to.add.<
71e0 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 /param>..........///.<exception.
7200 63 72 65 66 3d 22 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 cref="ArgumentException"><paramr
7220 65 66 20 6e 61 6d 65 3d 22 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 22 2f 3e 20 68 61 73 20 6e 6f ef.name="controlScheme"/>.has.no
7240 20 6e 61 6d 65 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 .name.</exception>..........///.
7260 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 <exception.cref="ArgumentNullExc
7280 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 2f 3e eption"><paramref.name="asset"/>
72a0 20 69 73 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 .is.<c>null</c>.</exception>....
72c0 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 49 6e 76 61 6c ......///.<exception.cref="Inval
72e0 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 22 3e 41 20 63 6f 6e 74 72 6f 6c 20 idOperationException">A.control.
7300 73 63 68 65 6d 65 20 77 69 74 68 20 74 68 65 20 73 61 6d 65 20 6e 61 6d 65 20 61 73 20 3c 70 61 scheme.with.the.same.name.as.<pa
7320 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 22 2f 3e 0d 0a 20 ramref.name="controlScheme"/>...
7340 20 20 20 20 20 20 20 2f 2f 2f 20 61 6c 72 65 61 64 79 20 65 78 69 73 74 73 20 69 6e 20 74 68 65 .......///.already.exists.in.the
7360 20 61 73 73 65 74 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f .asset.</exception>..........///
7380 20 3c 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 72 65 6d 61 72 6b .<remarks>..........///.</remark
73a0 73 3e 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 76 6f 69 64 20 41 s>..........public.static.void.A
73c0 64 64 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e ddControlScheme(this.InputAction
73e0 41 73 73 65 74 20 61 73 73 65 74 2c 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 Asset.asset,.InputControlScheme.
7400 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 controlScheme)..........{.......
7420 20 20 20 20 20 20 20 69 66 20 28 61 73 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 .......if.(asset.==.null).......
7440 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c ...........throw.new.ArgumentNul
7460 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 73 73 65 74 29 29 3b 0d 0a 20 20 20 20 lException(nameof(asset));......
7480 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 ........if.(string.IsNullOrEmpty
74a0 28 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e 6e 61 6d 65 29 29 0d 0a 20 20 20 20 20 20 20 20 20 (controlScheme.name))...........
74c0 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 .......throw.new.ArgumentExcepti
74e0 6f 6e 28 22 43 61 6e 6e 6f 74 20 61 64 64 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 77 69 on("Cannot.add.control.scheme.wi
7500 74 68 6f 75 74 20 6e 61 6d 65 20 74 6f 20 61 73 73 65 74 20 22 20 2b 20 61 73 73 65 74 2e 6e 61 thout.name.to.asset.".+.asset.na
7520 6d 65 2c 20 6e 61 6d 65 6f 66 28 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 29 29 3b 0d 0a 20 20 20 me,.nameof(controlScheme));.....
7540 20 20 20 20 20 20 20 20 20 69 66 20 28 61 73 73 65 74 2e 46 69 6e 64 43 6f 6e 74 72 6f 6c 53 63 .........if.(asset.FindControlSc
7560 68 65 6d 65 28 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e 6e 61 6d 65 29 20 21 3d 20 6e 75 6c 6c heme(controlScheme.name).!=.null
7580 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 49 6e 76 )..................throw.new.Inv
75a0 61 6c 69 64 4f 70 65 72 61 74 69 6f 6e 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 alidOperationException(.........
75c0 20 20 20 20 20 20 20 20 20 20 20 20 20 24 22 41 73 73 65 74 20 27 7b 61 73 73 65 74 2e 6e 61 6d .............$"Asset.'{asset.nam
75e0 65 7d 27 20 61 6c 72 65 61 64 79 20 63 6f 6e 74 61 69 6e 73 20 61 20 63 6f 6e 74 72 6f 6c 20 73 e}'.already.contains.a.control.s
7600 63 68 65 6d 65 20 63 61 6c 6c 65 64 20 27 7b 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e 6e 61 6d cheme.called.'{controlScheme.nam
7620 65 7d 27 22 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 41 72 72 61 79 48 65 6c 70 65 e}'");................ArrayHelpe
7640 72 73 2e 41 70 70 65 6e 64 28 72 65 66 20 61 73 73 65 74 2e 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 rs.Append(ref.asset.m_ControlSch
7660 65 6d 65 73 2c 20 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d emes,.controlScheme);..........}
7680 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 ............///.<summary>.......
76a0 20 20 20 2f 2f 2f 20 41 64 64 20 61 20 6e 65 77 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 ...///.Add.a.new.control.scheme.
76c0 74 6f 20 74 68 65 20 67 69 76 65 6e 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 61 73 73 to.the.given.<paramref.name="ass
76e0 65 74 22 2f 3e 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a et"/>...........///.</summary>..
7700 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 3e ........///.<param.name="asset">
7720 41 73 73 65 74 20 74 6f 20 61 64 64 20 74 68 65 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 Asset.to.add.the.control.scheme.
7740 74 6f 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 to.</param>..........///.<param.
7760 6e 61 6d 65 3d 22 6e 61 6d 65 22 3e 4e 61 6d 65 20 74 6f 20 67 69 76 65 20 74 6f 20 74 68 65 20 name="name">Name.to.give.to.the.
7780 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 2e 20 4d 75 73 74 20 62 65 20 75 6e 69 71 75 65 20 77 control.scheme..Must.be.unique.w
77a0 69 74 68 69 6e 20 74 68 65 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 73 20 6f 66 20 74 68 65 ithin.the.control.schemes.of.the
77c0 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 61 73 73 65 74 2e 20 41 6c 73 6f 20 75 73 65 64 20 61 ..........///.asset..Also.used.a
77e0 73 20 64 65 66 61 75 6c 74 20 6e 61 6d 65 20 6f 66 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 s.default.name.of.<see.cref="Inp
7800 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e 62 69 6e 64 69 6e 67 47 72 6f 75 70 22 3e 62 69 utControlScheme.bindingGroup">bi
7820 6e 64 69 6e 67 20 67 72 6f 75 70 3c 2f 73 65 65 3e 20 61 73 73 6f 63 69 61 74 65 64 0d 0a 20 20 nding.group</see>.associated....
7840 20 20 20 20 20 20 2f 2f 2f 20 77 69 74 68 20 74 68 65 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d ......///.with.the.control.schem
7860 65 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 72 65 74 75 72 6e 73 e.</param>..........///.<returns
7880 3e 53 79 6e 74 61 78 20 74 6f 20 61 6c 6c 6f 77 20 70 72 6f 76 69 64 69 6e 67 20 61 64 64 69 74 >Syntax.to.allow.providing.addit
78a0 69 6f 6e 61 6c 20 63 6f 6e 66 69 67 75 72 61 74 69 6f 6e 20 66 6f 72 20 74 68 65 20 6e 65 77 6c ional.configuration.for.the.newl
78c0 79 20 61 64 64 65 64 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 2e 3c 2f 72 65 74 75 72 6e 73 y.added.control.scheme.</returns
78e0 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 >..........///.<exception.cref="
7900 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 65 66 ArgumentNullException"><paramref
7920 20 6e 61 6d 65 3d 22 61 73 73 65 74 22 2f 3e 20 69 73 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 20 2d .name="asset"/>.is.<c>null</c>.-
7940 6f 72 2d 20 3c 70 61 72 61 6d 72 65 66 20 6e 61 6d 65 3d 22 6e 61 6d 65 22 2f 3e 0d 0a 20 20 20 or-.<paramref.name="name"/>.....
7960 20 20 20 20 20 2f 2f 2f 20 69 73 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 20 6f 72 20 65 6d 70 74 79 .....///.is.<c>null</c>.or.empty
7980 2e 3c 2f 65 78 63 65 70 74 69 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 .</exception>..........public.st
79a0 61 74 69 63 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 20 41 64 64 43 6f 6e 74 atic.ControlSchemeSyntax.AddCont
79c0 72 6f 6c 53 63 68 65 6d 65 28 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 20 rolScheme(this.InputActionAsset.
79e0 61 73 73 65 74 2c 20 73 74 72 69 6e 67 20 6e 61 6d 65 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a asset,.string.name)..........{..
7a00 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 73 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 0d 0a ............if.(asset.==.null)..
7a20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 ................throw.new.Argume
7a40 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 73 73 65 74 29 29 3b 0d ntNullException(nameof(asset));.
7a60 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 .............if.(string.IsNullOr
7a80 45 6d 70 74 79 28 6e 61 6d 65 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 Empty(name))..................th
7aa0 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 row.new.ArgumentNullException(na
7ac0 6d 65 6f 66 28 6e 61 6d 65 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 meof(name));................var.
7ae0 69 6e 64 65 78 20 3d 20 61 73 73 65 74 2e 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 73 2e 43 6f 75 index.=.asset.controlSchemes.Cou
7b00 6e 74 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 61 73 73 65 74 2e 41 64 64 43 6f 6e 74 72 6f nt;..............asset.AddContro
7b20 6c 53 63 68 65 6d 65 28 6e 65 77 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 28 6e lScheme(new.InputControlScheme(n
7b40 61 6d 65 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 ame));................return.new
7b60 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 28 61 73 73 65 74 2c 20 69 6e 64 65 .ControlSchemeSyntax(asset,.inde
7b80 78 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 x);..........}............///.<s
7ba0 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 52 65 6d 6f 76 65 20 74 68 65 20 ummary>..........///.Remove.the.
7bc0 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 77 69 74 68 20 74 68 65 20 67 69 76 65 6e 20 6e 61 control.scheme.with.the.given.na
7be0 6d 65 20 66 72 6f 6d 20 74 68 65 20 61 73 73 65 74 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 me.from.the.asset...........///.
7c00 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e </summary>..........///.<param.n
7c20 61 6d 65 3d 22 61 73 73 65 74 22 3e 41 73 73 65 74 20 74 6f 20 72 65 6d 6f 76 65 20 74 68 65 20 ame="asset">Asset.to.remove.the.
7c40 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 66 72 6f 6d 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 control.scheme.from.</param>....
7c60 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 6e 61 6d 65 22 3e 4e 61 6d ......///.<param.name="name">Nam
7c80 65 20 6f 66 20 74 68 65 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 2e 20 4d 61 74 63 68 69 6e e.of.the.control.scheme..Matchin
7ca0 67 20 69 73 20 63 61 73 65 2d 69 6e 73 65 6e 73 69 74 69 76 65 2e 3c 2f 70 61 72 61 6d 3e 0d 0a g.is.case-insensitive.</param>..
7cc0 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 65 78 63 65 70 74 69 6f 6e 20 63 72 65 66 3d 22 41 72 67 ........///.<exception.cref="Arg
7ce0 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 22 3e 3c 70 61 72 61 6d 72 65 66 20 6e 61 umentNullException"><paramref.na
7d00 6d 65 3d 22 61 73 73 65 74 22 2f 3e 20 69 73 20 6e 75 6c 6c 20 2d 6f 72 2d 20 3c 70 61 72 61 6d me="asset"/>.is.null.-or-.<param
7d20 72 65 66 20 6e 61 6d 65 3d 22 6e 61 6d 65 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 69 ref.name="name"/>..........///.i
7d40 73 20 3c 63 3e 6e 75 6c 6c 3c 2f 63 3e 20 6f 72 20 65 6d 70 74 79 2e 3c 2f 65 78 63 65 70 74 69 s.<c>null</c>.or.empty.</excepti
7d60 6f 6e 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 20 on>..........///.<remarks>......
7d80 20 20 20 20 2f 2f 2f 20 49 66 20 6e 6f 20 63 6f 6e 74 72 6f 6c 20 73 63 68 65 6d 65 20 77 69 74 ....///.If.no.control.scheme.wit
7da0 68 20 74 68 65 20 67 69 76 65 6e 20 6e 61 6d 65 20 63 61 6e 20 62 65 20 66 6f 75 6e 64 2c 20 74 h.the.given.name.can.be.found,.t
7dc0 68 65 20 6d 65 74 68 6f 64 20 64 6f 65 73 20 6e 6f 74 68 69 6e 67 2e 0d 0a 20 20 20 20 20 20 20 he.method.does.nothing..........
7de0 20 2f 2f 2f 20 3c 2f 72 65 6d 61 72 6b 73 3e 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 .///.</remarks>..........public.
7e00 73 74 61 74 69 63 20 76 6f 69 64 20 52 65 6d 6f 76 65 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 28 static.void.RemoveControlScheme(
7e20 74 68 69 73 20 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 20 61 73 73 65 74 2c 20 73 74 72 this.InputActionAsset.asset,.str
7e40 69 6e 67 20 6e 61 6d 65 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 ing.name)..........{............
7e60 20 20 69 66 20 28 61 73 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 ..if.(asset.==.null)............
7e80 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 ......throw.new.ArgumentNullExce
7ea0 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 73 73 65 74 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 ption(nameof(asset));...........
7ec0 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 6e 61 6d 65 ...if.(string.IsNullOrEmpty(name
7ee0 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 ))..................throw.new.Ar
7f00 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 6e 61 6d 65 29 gumentNullException(nameof(name)
7f20 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 69 6e 64 65 78 20 3d 20 61 73 );................var.index.=.as
7f40 73 65 74 2e 46 69 6e 64 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 49 6e 64 65 78 28 6e 61 6d 65 29 set.FindControlSchemeIndex(name)
7f60 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 6e 64 65 78 20 21 3d 20 2d 31 29 0d ;..............if.(index.!=.-1).
7f80 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 41 72 72 61 79 48 65 6c 70 65 72 73 2e 45 72 .................ArrayHelpers.Er
7fa0 61 73 65 41 74 28 72 65 66 20 61 73 73 65 74 2e 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 73 aseAt(ref.asset.m_ControlSchemes
7fc0 2c 20 69 6e 64 65 78 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 ,.index);..........}............
7fe0 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 public.static.InputControlScheme
8000 20 57 69 74 68 42 69 6e 64 69 6e 67 47 72 6f 75 70 28 74 68 69 73 20 49 6e 70 75 74 43 6f 6e 74 .WithBindingGroup(this.InputCont
8020 72 6f 6c 53 63 68 65 6d 65 20 73 63 68 65 6d 65 2c 20 73 74 72 69 6e 67 20 62 69 6e 64 69 6e 67 rolScheme.scheme,.string.binding
8040 47 72 6f 75 70 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 Group)..........{..............r
8060 65 74 75 72 6e 20 6e 65 77 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 28 73 63 eturn.new.ControlSchemeSyntax(sc
8080 68 65 6d 65 29 2e 57 69 74 68 42 69 6e 64 69 6e 67 47 72 6f 75 70 28 62 69 6e 64 69 6e 67 47 72 heme).WithBindingGroup(bindingGr
80a0 6f 75 70 29 2e 44 6f 6e 65 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 oup).Done();..........}.........
80c0 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 ...public.static.InputControlSch
80e0 65 6d 65 20 57 69 74 68 52 65 71 75 69 72 65 64 44 65 76 69 63 65 28 74 68 69 73 20 49 6e 70 75 eme.WithRequiredDevice(this.Inpu
8100 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 73 63 68 65 6d 65 2c 20 73 74 72 69 6e 67 20 63 6f tControlScheme.scheme,.string.co
8120 6e 74 72 6f 6c 50 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 ntrolPath)..........{...........
8140 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 ...return.new.ControlSchemeSynta
8160 78 28 73 63 68 65 6d 65 29 2e 57 69 74 68 52 65 71 75 69 72 65 64 44 65 76 69 63 65 28 63 6f 6e x(scheme).WithRequiredDevice(con
8180 74 72 6f 6c 50 61 74 68 29 2e 44 6f 6e 65 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a trolPath).Done();..........}....
81a0 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 49 6e 70 75 74 43 6f 6e 74 72 ........public.static.InputContr
81c0 6f 6c 53 63 68 65 6d 65 20 57 69 74 68 4f 70 74 69 6f 6e 61 6c 44 65 76 69 63 65 28 74 68 69 73 olScheme.WithOptionalDevice(this
81e0 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 73 63 68 65 6d 65 2c 20 73 74 72 69 .InputControlScheme.scheme,.stri
8200 6e 67 20 63 6f 6e 74 72 6f 6c 50 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 ng.controlPath)..........{......
8220 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 ........return.new.ControlScheme
8240 53 79 6e 74 61 78 28 73 63 68 65 6d 65 29 2e 57 69 74 68 4f 70 74 69 6f 6e 61 6c 44 65 76 69 63 Syntax(scheme).WithOptionalDevic
8260 65 28 63 6f 6e 74 72 6f 6c 50 61 74 68 29 2e 44 6f 6e 65 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 e(controlPath).Done();..........
8280 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 74 69 63 20 49 6e 70 75 74 }............public.static.Input
82a0 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 4f 72 57 69 74 68 52 65 71 75 69 72 65 64 44 65 76 69 ControlScheme.OrWithRequiredDevi
82c0 63 65 28 74 68 69 73 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 73 63 68 65 6d ce(this.InputControlScheme.schem
82e0 65 2c 20 73 74 72 69 6e 67 20 63 6f 6e 74 72 6f 6c 50 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 e,.string.controlPath)..........
8300 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e 65 77 20 43 6f 6e 74 72 6f {..............return.new.Contro
8320 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 28 73 63 68 65 6d 65 29 2e 4f 72 57 69 74 68 52 65 71 75 lSchemeSyntax(scheme).OrWithRequ
8340 69 72 65 64 44 65 76 69 63 65 28 63 6f 6e 74 72 6f 6c 50 61 74 68 29 2e 44 6f 6e 65 28 29 3b 0d iredDevice(controlPath).Done();.
8360 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 61 .........}............public.sta
8380 74 69 63 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 4f 72 57 69 74 68 4f 70 74 tic.InputControlScheme.OrWithOpt
83a0 69 6f 6e 61 6c 44 65 76 69 63 65 28 74 68 69 73 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 ionalDevice(this.InputControlSch
83c0 65 6d 65 20 73 63 68 65 6d 65 2c 20 73 74 72 69 6e 67 20 63 6f 6e 74 72 6f 6c 50 61 74 68 29 0d eme.scheme,.string.controlPath).
83e0 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6e .........{..............return.n
8400 65 77 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 28 73 63 68 65 6d 65 29 2e 4f ew.ControlSchemeSyntax(scheme).O
8420 72 57 69 74 68 4f 70 74 69 6f 6e 61 6c 44 65 76 69 63 65 28 63 6f 6e 74 72 6f 6c 50 61 74 68 29 rWithOptionalDevice(controlPath)
8440 2e 44 6f 6e 65 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 2f .Done();..........}............/
8460 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 53 79 6e 74 61 78 //.<summary>..........///.Syntax
8480 20 74 6f 20 63 6f 6e 66 69 67 75 72 65 20 61 20 62 69 6e 64 69 6e 67 20 61 64 64 65 64 20 74 6f .to.configure.a.binding.added.to
84a0 20 61 6e 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 41 63 74 69 6f 6e 22 2f 3e 20 6f 72 .an.<see.cref="InputAction"/>.or
84c0 20 61 6e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 .an..........///.<see.cref="Inpu
84e0 74 41 63 74 69 6f 6e 4d 61 70 22 2f 3e 2e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 tActionMap"/>...........///.</su
8500 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c 73 6f 20 63 72 65 mmary>..........///.<seealso.cre
8520 66 3d 22 41 64 64 42 69 6e 64 69 6e 67 28 49 6e 70 75 74 41 63 74 69 6f 6e 2c 49 6e 70 75 74 42 f="AddBinding(InputAction,InputB
8540 69 6e 64 69 6e 67 29 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 72 75 63 inding)"/>..........public.struc
8560 74 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 t.BindingSyntax..........{......
8580 20 20 20 20 20 20 20 20 70 72 69 76 61 74 65 20 72 65 61 64 6f 6e 6c 79 20 49 6e 70 75 74 41 63 ........private.readonly.InputAc
85a0 74 69 6f 6e 4d 61 70 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 tionMap.m_ActionMap;............
85c0 20 20 70 72 69 76 61 74 65 20 72 65 61 64 6f 6e 6c 79 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 6d ..private.readonly.InputAction.m
85e0 5f 41 63 74 69 6f 6e 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 74 65 72 6e 61 6c 20 72 _Action;..............internal.r
8600 65 61 64 6f 6e 6c 79 20 69 6e 74 20 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 3b 0d 0a 0d 0a 20 eadonly.int.m_BindingIndex;.....
8620 20 20 20 20 20 20 20 20 20 20 20 69 6e 74 65 72 6e 61 6c 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 ...........internal.BindingSynta
8640 78 28 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 70 20 6d 61 70 2c 20 49 6e 70 75 74 41 63 74 69 6f x(InputActionMap.map,.InputActio
8660 6e 20 61 63 74 69 6f 6e 2c 20 69 6e 74 20 62 69 6e 64 69 6e 67 49 6e 64 65 78 29 0d 0a 20 20 20 n.action,.int.bindingIndex).....
8680 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 .........{..................m_Ac
86a0 74 69 6f 6e 4d 61 70 20 3d 20 6d 61 70 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 tionMap.=.map;..................
86c0 6d 5f 41 63 74 69 6f 6e 20 3d 20 61 63 74 69 6f 6e 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 m_Action.=.action;..............
86e0 20 20 20 20 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 20 3d 20 62 69 6e 64 69 6e 67 49 6e 64 65 ....m_BindingIndex.=.bindingInde
8700 78 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 x;..............}...............
8720 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 20 .///.<summary>..............///.
8740 53 65 74 20 74 68 65 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e 70 75 74 42 69 6e 64 69 6e 67 2e Set.the.<see.cref="InputBinding.
8760 6e 61 6d 65 22 2f 3e 20 6f 66 20 74 68 65 20 62 69 6e 64 69 6e 67 2e 0d 0a 20 20 20 20 20 20 20 name"/>.of.the.binding..........
8780 20 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 .....///.</summary>.............
87a0 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 6e 61 6d 65 22 3e 4e 61 6d 65 20 66 6f 72 .///.<param.name="name">Name.for
87c0 20 74 68 65 20 62 69 6e 64 69 6e 67 2e 3c 2f 70 61 72 61 6d 3e 0d 0a 20 20 20 20 20 20 20 20 20 .the.binding.</param>...........
87e0 20 20 20 2f 2f 2f 20 3c 72 65 74 75 72 6e 73 3e 54 68 65 20 73 61 6d 65 20 62 69 6e 64 69 6e 67 ...///.<returns>The.same.binding
8800 20 73 79 6e 74 61 78 20 66 6f 72 20 66 75 72 74 68 65 72 20 63 6f 6e 66 69 67 75 72 61 74 69 6f .syntax.for.further.configuratio
8820 6e 2e 3c 2f 72 65 74 75 72 6e 73 3e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 n.</returns>..............///.<s
8840 65 65 61 6c 73 6f 20 63 72 65 66 3d 22 49 6e 70 75 74 42 69 6e 64 69 6e 67 2e 6e 61 6d 65 22 2f eealso.cref="InputBinding.name"/
8860 3e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c 73 6f 20 63 72 65 66 >..............///.<seealso.cref
8880 3d 22 41 64 64 42 69 6e 64 69 6e 67 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 ="AddBinding"/>..............pub
88a0 6c 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 57 69 74 68 4e 61 6d 65 28 73 74 72 69 6e lic.BindingSyntax.WithName(strin
88c0 67 20 6e 61 6d 65 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 g.name)..............{..........
88e0 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 5b 6d ........m_ActionMap.m_Bindings[m
8900 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 5d 2e 6e 61 6d 65 20 3d 20 6e 61 6d 65 3b 0d 0a 20 20 20 _BindingIndex].name.=.name;.....
8920 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 43 6c 65 61 72 50 65 .............m_ActionMap.ClearPe
8940 72 41 63 74 69 6f 6e 43 61 63 68 65 64 42 69 6e 64 69 6e 67 44 61 74 61 28 29 3b 0d 0a 20 20 20 rActionCachedBindingData();.....
8960 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 4c 61 7a 79 52 65 73 .............m_ActionMap.LazyRes
8980 6f 6c 76 65 42 69 6e 64 69 6e 67 73 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 olveBindings();.................
89a0 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a .return.this;..............}....
89c0 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 73 75 6d 6d 61 72 79 3e 0d 0a 20 20 20 20 20 ............///.<summary>.......
89e0 20 20 20 20 20 20 20 2f 2f 2f 20 53 65 74 20 74 68 65 20 3c 73 65 65 20 63 72 65 66 3d 22 49 6e .......///.Set.the.<see.cref="In
8a00 70 75 74 42 69 6e 64 69 6e 67 2e 70 61 74 68 22 2f 3e 20 6f 66 20 74 68 65 20 62 69 6e 64 69 6e putBinding.path"/>.of.the.bindin
8a20 67 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 2f 73 75 6d 6d 61 72 79 3e 0d 0a g...............///.</summary>..
8a40 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 70 61 72 61 6d 20 6e 61 6d 65 3d 22 70 61 74 ............///.<param.name="pat
8a60 68 22 3e 50 61 74 68 20 66 6f 72 20 74 68 65 20 62 69 6e 64 69 6e 67 2e 3c 2f 70 61 72 61 6d 3e h">Path.for.the.binding.</param>
8a80 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 20 3c 72 65 74 75 72 6e 73 3e 54 68 65 20 73 ..............///.<returns>The.s
8aa0 61 6d 65 20 62 69 6e 64 69 6e 67 20 73 79 6e 74 61 78 20 66 6f 72 20 66 75 72 74 68 65 72 20 63 ame.binding.syntax.for.further.c
8ac0 6f 6e 66 69 67 75 72 61 74 69 6f 6e 2e 3c 2f 72 65 74 75 72 6e 73 3e 0d 0a 20 20 20 20 20 20 20 onfiguration.</returns>.........
8ae0 20 20 20 20 20 2f 2f 2f 20 3c 73 65 65 61 6c 73 6f 20 63 72 65 66 3d 22 49 6e 70 75 74 42 69 6e .....///.<seealso.cref="InputBin
8b00 64 69 6e 67 2e 70 61 74 68 22 2f 3e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 ding.path"/>..............public
8b20 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 57 69 74 68 50 61 74 68 28 73 74 72 69 6e 67 20 70 .BindingSyntax.WithPath(string.p
8b40 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 ath)..............{.............
8b60 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 5b 6d 5f 42 69 .....m_ActionMap.m_Bindings[m_Bi
8b80 6e 64 69 6e 67 49 6e 64 65 78 5d 2e 70 61 74 68 20 3d 20 70 61 74 68 3b 0d 0a 20 20 20 20 20 20 ndingIndex].path.=.path;........
8ba0 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 43 6c 65 61 72 50 65 72 41 63 ..........m_ActionMap.ClearPerAc
8bc0 74 69 6f 6e 43 61 63 68 65 64 42 69 6e 64 69 6e 67 44 61 74 61 28 29 3b 0d 0a 20 20 20 20 20 20 tionCachedBindingData();........
8be0 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 4c 61 7a 79 52 65 73 6f 6c 76 ..........m_ActionMap.LazyResolv
8c00 65 42 69 6e 64 69 6e 67 73 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 eBindings();..................re
8c20 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 turn.this;..............}.......
8c40 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 57 69 .........public.BindingSyntax.Wi
8c60 74 68 47 72 6f 75 70 28 73 74 72 69 6e 67 20 67 72 6f 75 70 29 0d 0a 20 20 20 20 20 20 20 20 20 thGroup(string.group)...........
8c80 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 ...{..................if.(string
8ca0 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 67 72 6f 75 70 29 29 0d 0a 20 20 20 20 20 20 20 20 .IsNullOrEmpty(group))..........
8cc0 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 45 78 ............throw.new.ArgumentEx
8ce0 63 65 70 74 69 6f 6e 28 22 47 72 6f 75 70 20 6e 61 6d 65 20 63 61 6e 6e 6f 74 20 62 65 20 6e 75 ception("Group.name.cannot.be.nu
8d00 6c 6c 20 6f 72 20 65 6d 70 74 79 22 2c 20 6e 61 6d 65 6f 66 28 67 72 6f 75 70 29 29 3b 0d 0a 20 ll.or.empty",.nameof(group));...
8d20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 67 72 6f 75 70 2e 49 6e 64 65 78 4f 66 ...............if.(group.IndexOf
8d40 28 49 6e 70 75 74 42 69 6e 64 69 6e 67 2e 53 65 70 61 72 61 74 6f 72 29 20 21 3d 20 2d 31 29 0d (InputBinding.Separator).!=.-1).
8d60 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 .....................throw.new.A
8d80 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 rgumentException(...............
8da0 20 20 20 20 20 20 20 20 20 20 20 24 22 47 72 6f 75 70 20 6e 61 6d 65 20 63 61 6e 6e 6f 74 20 63 ...........$"Group.name.cannot.c
8dc0 6f 6e 74 61 69 6e 20 73 65 70 61 72 61 74 6f 72 20 63 68 61 72 61 63 74 65 72 20 27 7b 49 6e 70 ontain.separator.character.'{Inp
8de0 75 74 42 69 6e 64 69 6e 67 2e 53 65 70 61 72 61 74 6f 72 7d 27 22 2c 20 6e 61 6d 65 6f 66 28 67 utBinding.Separator}'",.nameof(g
8e00 72 6f 75 70 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 roup));....................retur
8e20 6e 20 57 69 74 68 47 72 6f 75 70 73 28 67 72 6f 75 70 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 n.WithGroups(group);............
8e40 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 42 69 6e 64 69 6e ..}................public.Bindin
8e60 67 53 79 6e 74 61 78 20 57 69 74 68 47 72 6f 75 70 73 28 73 74 72 69 6e 67 20 67 72 6f 75 70 73 gSyntax.WithGroups(string.groups
8e80 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 )..............{................
8ea0 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 67 72 6f 75 70 ..if.(string.IsNullOrEmpty(group
8ec0 73 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 s))......................return.
8ee0 74 68 69 73 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4a 6f 69 6e this;....................//.Join
8f00 20 77 69 74 68 20 65 78 69 73 74 69 6e 67 20 67 72 6f 75 70 2c 20 69 66 20 61 6e 79 2e 0d 0a 20 .with.existing.group,.if.any....
8f20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 63 75 72 72 65 6e 74 47 72 6f 75 70 73 ...............var.currentGroups
8f40 20 3d 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 5b 6d 5f 42 69 6e 64 .=.m_ActionMap.m_Bindings[m_Bind
8f60 69 6e 67 49 6e 64 65 78 5d 2e 67 72 6f 75 70 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 ingIndex].groups;...............
8f80 20 20 20 69 66 20 28 21 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 63 75 72 ...if.(!string.IsNullOrEmpty(cur
8fa0 72 65 6e 74 47 72 6f 75 70 73 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 rentGroups))....................
8fc0 20 20 67 72 6f 75 70 73 20 3d 20 73 74 72 69 6e 67 2e 4a 6f 69 6e 28 49 6e 70 75 74 42 69 6e 64 ..groups.=.string.Join(InputBind
8fe0 69 6e 67 2e 6b 53 65 70 61 72 61 74 6f 72 53 74 72 69 6e 67 2c 20 63 75 72 72 65 6e 74 47 72 6f ing.kSeparatorString,.currentGro
9000 75 70 73 2c 20 67 72 6f 75 70 73 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 ups,.groups);...................
9020 20 2f 2f 20 53 65 74 20 67 72 6f 75 70 73 20 6f 6e 20 62 69 6e 64 69 6e 67 2e 0d 0a 20 20 20 20 .//.Set.groups.on.binding.......
9040 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e ............m_ActionMap.m_Bindin
9060 67 73 5b 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 5d 2e 67 72 6f 75 70 73 20 3d 20 67 72 6f 75 gs[m_BindingIndex].groups.=.grou
9080 70 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 ps;..................m_ActionMap
90a0 2e 43 6c 65 61 72 50 65 72 41 63 74 69 6f 6e 43 61 63 68 65 64 42 69 6e 64 69 6e 67 44 61 74 61 .ClearPerActionCachedBindingData
90c0 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 ();..................m_ActionMap
90e0 2e 4c 61 7a 79 52 65 73 6f 6c 76 65 42 69 6e 64 69 6e 67 73 28 29 3b 0d 0a 0d 0a 20 20 20 20 20 .LazyResolveBindings();.........
9100 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 ...........return.this;.........
9120 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 42 69 6e .....}................public.Bin
9140 64 69 6e 67 53 79 6e 74 61 78 20 57 69 74 68 49 6e 74 65 72 61 63 74 69 6f 6e 28 73 74 72 69 6e dingSyntax.WithInteraction(strin
9160 67 20 69 6e 74 65 72 61 63 74 69 6f 6e 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 g.interaction)..............{...
9180 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c ...............if.(string.IsNull
91a0 4f 72 45 6d 70 74 79 28 69 6e 74 65 72 61 63 74 69 6f 6e 29 29 0d 0a 20 20 20 20 20 20 20 20 20 OrEmpty(interaction))...........
91c0 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 45 78 63 ...........throw.new.ArgumentExc
91e0 65 70 74 69 6f 6e 28 22 49 6e 74 65 72 61 63 74 69 6f 6e 20 63 61 6e 6e 6f 74 20 62 65 20 6e 75 eption("Interaction.cannot.be.nu
9200 6c 6c 20 6f 72 20 65 6d 70 74 79 22 2c 20 6e 61 6d 65 6f 66 28 69 6e 74 65 72 61 63 74 69 6f 6e ll.or.empty",.nameof(interaction
9220 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 69 6e 74 65 72 61 63 ));..................if.(interac
9240 74 69 6f 6e 2e 49 6e 64 65 78 4f 66 28 49 6e 70 75 74 42 69 6e 64 69 6e 67 2e 53 65 70 61 72 61 tion.IndexOf(InputBinding.Separa
9260 74 6f 72 29 20 21 3d 20 2d 31 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 tor).!=.-1).....................
9280 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 .throw.new.ArgumentException(...
92a0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 22 49 6e 74 65 72 61 63 .......................$"Interac
92c0 74 69 6f 6e 20 73 74 72 69 6e 67 20 63 61 6e 6e 6f 74 20 63 6f 6e 74 61 69 6e 20 73 65 70 61 72 tion.string.cannot.contain.separ
92e0 61 74 6f 72 20 63 68 61 72 61 63 74 65 72 20 27 7b 49 6e 70 75 74 42 69 6e 64 69 6e 67 2e 53 65 ator.character.'{InputBinding.Se
9300 70 61 72 61 74 6f 72 7d 27 22 2c 20 6e 61 6d 65 6f 66 28 69 6e 74 65 72 61 63 74 69 6f 6e 29 29 parator}'",.nameof(interaction))
9320 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 57 69 74 68 ;....................return.With
9340 49 6e 74 65 72 61 63 74 69 6f 6e 73 28 69 6e 74 65 72 61 63 74 69 6f 6e 29 3b 0d 0a 20 20 20 20 Interactions(interaction);......
9360 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 ........}................public.
9380 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 57 69 74 68 49 6e 74 65 72 61 63 74 69 6f 6e 73 28 73 BindingSyntax.WithInteractions(s
93a0 74 72 69 6e 67 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 tring.interactions).............
93c0 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 .{..................if.(string.I
93e0 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 69 6e 74 65 72 61 63 74 69 6f 6e 73 29 29 0d 0a 20 20 20 sNullOrEmpty(interactions)).....
9400 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 0d .................return.this;...
9420 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 4a 6f 69 6e 20 77 69 74 68 20 65 78 .................//.Join.with.ex
9440 69 73 74 69 6e 67 20 69 6e 74 65 72 61 63 74 69 6f 6e 20 73 74 72 69 6e 67 2c 20 69 66 20 61 6e isting.interaction.string,.if.an
9460 79 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 63 75 72 72 65 6e 74 49 y...................var.currentI
9480 6e 74 65 72 61 63 74 69 6f 6e 73 20 3d 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 nteractions.=.m_ActionMap.m_Bind
94a0 69 6e 67 73 5b 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 5d 2e 69 6e 74 65 72 61 63 74 69 6f 6e ings[m_BindingIndex].interaction
94c0 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 21 73 74 72 69 6e 67 2e s;..................if.(!string.
94e0 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 63 75 72 72 65 6e 74 49 6e 74 65 72 61 63 74 69 6f 6e IsNullOrEmpty(currentInteraction
9500 73 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 74 65 72 61 63 s))......................interac
9520 74 69 6f 6e 73 20 3d 20 73 74 72 69 6e 67 2e 4a 6f 69 6e 28 49 6e 70 75 74 42 69 6e 64 69 6e 67 tions.=.string.Join(InputBinding
9540 2e 6b 53 65 70 61 72 61 74 6f 72 53 74 72 69 6e 67 2c 20 63 75 72 72 65 6e 74 49 6e 74 65 72 61 .kSeparatorString,.currentIntera
9560 63 74 69 6f 6e 73 2c 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 ctions,.interactions);..........
9580 20 20 20 20 20 20 20 20 20 20 2f 2f 20 53 65 74 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 20 6f 6e ..........//.Set.interactions.on
95a0 20 62 69 6e 64 69 6e 67 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 .binding...................m_Act
95c0 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 5b 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 ionMap.m_Bindings[m_BindingIndex
95e0 5d 2e 69 6e 74 65 72 61 63 74 69 6f 6e 73 20 3d 20 69 6e 74 65 72 61 63 74 69 6f 6e 73 3b 0d 0a ].interactions.=.interactions;..
9600 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 43 6c 65 61 ................m_ActionMap.Clea
9620 72 50 65 72 41 63 74 69 6f 6e 43 61 63 68 65 64 42 69 6e 64 69 6e 67 44 61 74 61 28 29 3b 0d 0a rPerActionCachedBindingData();..
9640 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 4c 61 7a 79 ................m_ActionMap.Lazy
9660 52 65 73 6f 6c 76 65 42 69 6e 64 69 6e 67 73 28 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 ResolveBindings();..............
9680 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 ......return.this;..............
96a0 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 42 69 6e 64 69 6e 67 53 }................public.BindingS
96c0 79 6e 74 61 78 20 57 69 74 68 49 6e 74 65 72 61 63 74 69 6f 6e 3c 54 49 6e 74 65 72 61 63 74 69 yntax.WithInteraction<TInteracti
96e0 6f 6e 3e 28 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 77 68 65 72 65 20 54 49 6e on>()..................where.TIn
9700 74 65 72 61 63 74 69 6f 6e 20 3a 20 49 49 6e 70 75 74 49 6e 74 65 72 61 63 74 69 6f 6e 0d 0a 20 teraction.:.IInputInteraction...
9720 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 76 61 ...........{..................va
9740 72 20 69 6e 74 65 72 61 63 74 69 6f 6e 4e 61 6d 65 20 3d 20 49 6e 70 75 74 50 72 6f 63 65 73 73 r.interactionName.=.InputProcess
9760 6f 72 2e 73 5f 50 72 6f 63 65 73 73 6f 72 73 2e 46 69 6e 64 4e 61 6d 65 46 6f 72 54 79 70 65 28 or.s_Processors.FindNameForType(
9780 74 79 70 65 6f 66 28 54 49 6e 74 65 72 61 63 74 69 6f 6e 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 typeof(TInteraction));..........
97a0 20 20 20 20 20 20 20 20 69 66 20 28 69 6e 74 65 72 61 63 74 69 6f 6e 4e 61 6d 65 2e 49 73 45 6d ........if.(interactionName.IsEm
97c0 70 74 79 28 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f pty())......................thro
97e0 77 20 6e 65 77 20 4e 6f 74 53 75 70 70 6f 72 74 65 64 45 78 63 65 70 74 69 6f 6e 28 24 22 54 79 w.new.NotSupportedException($"Ty
9800 70 65 20 27 7b 74 79 70 65 6f 66 28 54 49 6e 74 65 72 61 63 74 69 6f 6e 29 7d 27 20 68 61 73 20 pe.'{typeof(TInteraction)}'.has.
9820 6e 6f 74 20 62 65 65 6e 20 72 65 67 69 73 74 65 72 65 64 20 61 73 20 61 20 70 72 6f 63 65 73 73 not.been.registered.as.a.process
9840 6f 72 22 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 or");....................return.
9860 57 69 74 68 49 6e 74 65 72 61 63 74 69 6f 6e 28 69 6e 74 65 72 61 63 74 69 6f 6e 4e 61 6d 65 29 WithInteraction(interactionName)
9880 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 ;..............}................
98a0 70 75 62 6c 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 57 69 74 68 50 72 6f 63 65 73 73 public.BindingSyntax.WithProcess
98c0 6f 72 28 73 74 72 69 6e 67 20 70 72 6f 63 65 73 73 6f 72 29 0d 0a 20 20 20 20 20 20 20 20 20 20 or(string.processor)............
98e0 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e ..{..................if.(string.
9900 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 70 72 6f 63 65 73 73 6f 72 29 29 0d 0a 20 20 20 20 20 IsNullOrEmpty(processor)).......
9920 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e ...............throw.new.Argumen
9940 74 45 78 63 65 70 74 69 6f 6e 28 22 50 72 6f 63 65 73 73 6f 72 20 63 61 6e 6e 6f 74 20 62 65 20 tException("Processor.cannot.be.
9960 6e 75 6c 6c 20 6f 72 20 65 6d 70 74 79 22 2c 20 6e 61 6d 65 6f 66 28 70 72 6f 63 65 73 73 6f 72 null.or.empty",.nameof(processor
9980 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 70 72 6f 63 65 73 73 ));..................if.(process
99a0 6f 72 2e 49 6e 64 65 78 4f 66 28 49 6e 70 75 74 42 69 6e 64 69 6e 67 2e 53 65 70 61 72 61 74 6f or.IndexOf(InputBinding.Separato
99c0 72 29 20 21 3d 20 2d 31 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 r).!=.-1)......................t
99e0 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 69 6f 6e 28 0d 0a 20 20 20 hrow.new.ArgumentException(.....
9a00 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 22 49 6e 74 65 72 61 63 74 69 .....................$"Interacti
9a20 6f 6e 20 73 74 72 69 6e 67 20 63 61 6e 6e 6f 74 20 63 6f 6e 74 61 69 6e 20 73 65 70 61 72 61 74 on.string.cannot.contain.separat
9a40 6f 72 20 63 68 61 72 61 63 74 65 72 20 27 7b 49 6e 70 75 74 42 69 6e 64 69 6e 67 2e 53 65 70 61 or.character.'{InputBinding.Sepa
9a60 72 61 74 6f 72 7d 27 22 2c 20 6e 61 6d 65 6f 66 28 70 72 6f 63 65 73 73 6f 72 29 29 3b 0d 0a 0d rator}'",.nameof(processor));...
9a80 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 57 69 74 68 50 72 6f 63 .................return.WithProc
9aa0 65 73 73 6f 72 73 28 70 72 6f 63 65 73 73 6f 72 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 essors(processor);..............
9ac0 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 42 69 6e 64 69 6e 67 53 }................public.BindingS
9ae0 79 6e 74 61 78 20 57 69 74 68 50 72 6f 63 65 73 73 6f 72 73 28 73 74 72 69 6e 67 20 70 72 6f 63 yntax.WithProcessors(string.proc
9b00 65 73 73 6f 72 73 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 essors)..............{..........
9b20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 ........if.(string.IsNullOrEmpty
9b40 28 70 72 6f 63 65 73 73 6f 72 73 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 (processors))...................
9b60 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 ...return.this;.................
9b80 20 20 20 2f 2f 20 4a 6f 69 6e 20 77 69 74 68 20 65 78 69 73 74 69 6e 67 20 70 72 6f 63 65 73 73 ...//.Join.with.existing.process
9ba0 6f 72 20 73 74 72 69 6e 67 2c 20 69 66 20 61 6e 79 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 or.string,.if.any...............
9bc0 20 20 20 20 76 61 72 20 63 75 72 72 65 6e 74 50 72 6f 63 65 73 73 6f 72 73 20 3d 20 6d 5f 41 63 ....var.currentProcessors.=.m_Ac
9be0 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 5b 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 tionMap.m_Bindings[m_BindingInde
9c00 78 5d 2e 70 72 6f 63 65 73 73 6f 72 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 x].processors;..................
9c20 69 66 20 28 21 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 63 75 72 72 65 6e if.(!string.IsNullOrEmpty(curren
9c40 74 50 72 6f 63 65 73 73 6f 72 73 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 tProcessors))...................
9c60 20 20 20 70 72 6f 63 65 73 73 6f 72 73 20 3d 20 73 74 72 69 6e 67 2e 4a 6f 69 6e 28 49 6e 70 75 ...processors.=.string.Join(Inpu
9c80 74 42 69 6e 64 69 6e 67 2e 6b 53 65 70 61 72 61 74 6f 72 53 74 72 69 6e 67 2c 20 63 75 72 72 65 tBinding.kSeparatorString,.curre
9ca0 6e 74 50 72 6f 63 65 73 73 6f 72 73 2c 20 70 72 6f 63 65 73 73 6f 72 73 29 3b 0d 0a 0d 0a 20 20 ntProcessors,.processors);......
9cc0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 53 65 74 20 70 72 6f 63 65 73 73 6f 72 73 20 ..............//.Set.processors.
9ce0 6f 6e 20 62 69 6e 64 69 6e 67 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 on.binding...................m_A
9d00 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 5b 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 ctionMap.m_Bindings[m_BindingInd
9d20 65 78 5d 2e 70 72 6f 63 65 73 73 6f 72 73 20 3d 20 70 72 6f 63 65 73 73 6f 72 73 3b 0d 0a 20 20 ex].processors.=.processors;....
9d40 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 43 6c 65 61 72 50 ..............m_ActionMap.ClearP
9d60 65 72 41 63 74 69 6f 6e 43 61 63 68 65 64 42 69 6e 64 69 6e 67 44 61 74 61 28 29 3b 0d 0a 20 20 erActionCachedBindingData();....
9d80 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 4c 61 7a 79 52 65 ..............m_ActionMap.LazyRe
9da0 73 6f 6c 76 65 42 69 6e 64 69 6e 67 73 28 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 solveBindings();................
9dc0 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d ....return.this;..............}.
9de0 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 42 69 6e 64 69 6e 67 53 79 6e ...............public.BindingSyn
9e00 74 61 78 20 57 69 74 68 50 72 6f 63 65 73 73 6f 72 3c 54 50 72 6f 63 65 73 73 6f 72 3e 28 29 0d tax.WithProcessor<TProcessor>().
9e20 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 .............{..................
9e40 76 61 72 20 70 72 6f 63 65 73 73 6f 72 4e 61 6d 65 20 3d 20 49 6e 70 75 74 50 72 6f 63 65 73 73 var.processorName.=.InputProcess
9e60 6f 72 2e 73 5f 50 72 6f 63 65 73 73 6f 72 73 2e 46 69 6e 64 4e 61 6d 65 46 6f 72 54 79 70 65 28 or.s_Processors.FindNameForType(
9e80 74 79 70 65 6f 66 28 54 50 72 6f 63 65 73 73 6f 72 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 typeof(TProcessor));............
9ea0 20 20 20 20 20 20 69 66 20 28 70 72 6f 63 65 73 73 6f 72 4e 61 6d 65 2e 49 73 45 6d 70 74 79 28 ......if.(processorName.IsEmpty(
9ec0 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 ))......................throw.ne
9ee0 77 20 4e 6f 74 53 75 70 70 6f 72 74 65 64 45 78 63 65 70 74 69 6f 6e 28 24 22 54 79 70 65 20 27 w.NotSupportedException($"Type.'
9f00 7b 74 79 70 65 6f 66 28 54 50 72 6f 63 65 73 73 6f 72 29 7d 27 20 68 61 73 20 6e 6f 74 20 62 65 {typeof(TProcessor)}'.has.not.be
9f20 65 6e 20 72 65 67 69 73 74 65 72 65 64 20 61 73 20 61 20 70 72 6f 63 65 73 73 6f 72 22 29 3b 0d en.registered.as.a.processor");.
9f40 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 57 69 74 68 50 72 ...................return.WithPr
9f60 6f 63 65 73 73 6f 72 28 70 72 6f 63 65 73 73 6f 72 4e 61 6d 65 29 3b 0d 0a 20 20 20 20 20 20 20 ocessor(processorName);.........
9f80 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 42 69 6e .....}................public.Bin
9fa0 64 69 6e 67 53 79 6e 74 61 78 20 54 72 69 67 67 65 72 69 6e 67 28 49 6e 70 75 74 41 63 74 69 6f dingSyntax.Triggering(InputActio
9fc0 6e 20 61 63 74 69 6f 6e 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 n.action)..............{........
9fe0 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 20 3d 3d 20 6e 75 6c 6c 29 0d 0a 20 ..........if.(action.==.null)...
a000 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 ...................throw.new.Arg
a020 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e umentNullException(nameof(action
a040 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 61 63 74 69 6f 6e 2e ));..................if.(action.
a060 69 73 53 69 6e 67 6c 65 74 6f 6e 41 63 74 69 6f 6e 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 isSingletonAction)..............
a080 20 20 20 20 20 20 20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 45 78 63 65 70 74 ........throw.new.ArgumentExcept
a0a0 69 6f 6e 28 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 24 22 ion(..........................$"
a0c0 43 61 6e 6e 6f 74 20 63 68 61 6e 67 65 20 74 68 65 20 61 63 74 69 6f 6e 20 61 20 62 69 6e 64 69 Cannot.change.the.action.a.bindi
a0e0 6e 67 20 74 72 69 67 67 65 72 73 20 6f 6e 20 73 69 6e 67 6c 65 74 6f 6e 20 61 63 74 69 6f 6e 20 ng.triggers.on.singleton.action.
a100 27 7b 61 63 74 69 6f 6e 7d 27 22 2c 20 6e 61 6d 65 6f 66 28 61 63 74 69 6f 6e 29 29 3b 0d 0a 20 '{action}'",.nameof(action));...
a120 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e ...............m_ActionMap.m_Bin
a140 64 69 6e 67 73 5b 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 5d 2e 61 63 74 69 6f 6e 20 3d 20 61 dings[m_BindingIndex].action.=.a
a160 63 74 69 6f 6e 2e 6e 61 6d 65 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 ction.name;..................m_A
a180 63 74 69 6f 6e 4d 61 70 2e 43 6c 65 61 72 50 65 72 41 63 74 69 6f 6e 43 61 63 68 65 64 42 69 6e ctionMap.ClearPerActionCachedBin
a1a0 64 69 6e 67 44 61 74 61 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 dingData();..................m_A
a1c0 63 74 69 6f 6e 4d 61 70 2e 4c 61 7a 79 52 65 73 6f 6c 76 65 42 69 6e 64 69 6e 67 73 28 29 3b 0d ctionMap.LazyResolveBindings();.
a1e0 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 .................return.this;...
a200 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c ...........}................publ
a220 69 63 20 42 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 54 6f 28 49 6e 70 75 74 42 69 6e 64 69 6e 67 ic.BindingSyntax.To(InputBinding
a240 20 62 69 6e 64 69 6e 67 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 .binding)..............{........
a260 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 ..........m_ActionMap.m_Bindings
a280 5b 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 5d 20 3d 20 62 69 6e 64 69 6e 67 3b 0d 0a 20 20 20 [m_BindingIndex].=.binding;.....
a2a0 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 43 6c 65 61 72 50 65 .............m_ActionMap.ClearPe
a2c0 72 41 63 74 69 6f 6e 43 61 63 68 65 64 42 69 6e 64 69 6e 67 44 61 74 61 28 29 3b 0d 0a 20 20 20 rActionCachedBindingData();.....
a2e0 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 4c 61 7a 79 52 65 73 .............m_ActionMap.LazyRes
a300 6f 6c 76 65 42 69 6e 64 69 6e 67 73 28 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 olveBindings();.................
a320 20 20 20 2f 2f 20 49 66 20 69 74 27 73 20 61 20 73 69 6e 67 6c 65 74 6f 6e 20 61 63 74 69 6f 6e ...//.If.it's.a.singleton.action
a340 2c 20 77 65 20 66 6f 72 63 65 20 74 68 65 20 62 69 6e 64 69 6e 67 20 74 6f 20 73 74 61 79 20 77 ,.we.force.the.binding.to.stay.w
a360 69 74 68 20 74 68 65 20 61 63 74 69 6f 6e 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 ith.the.action..................
a380 20 69 66 20 28 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 53 69 6e 67 6c 65 74 6f 6e 41 63 74 69 .if.(m_ActionMap.m_SingletonActi
a3a0 6f 6e 20 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 on.!=.null).....................
a3c0 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 5b 6d 5f 42 69 6e 64 69 6e .m_ActionMap.m_Bindings[m_Bindin
a3e0 67 49 6e 64 65 78 5d 2e 61 63 74 69 6f 6e 20 3d 20 6d 5f 41 63 74 69 6f 6e 2e 6e 61 6d 65 3b 0d gIndex].action.=.m_Action.name;.
a400 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d ...................return.this;.
a420 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 .............}................pu
a440 62 6c 69 63 20 76 6f 69 64 20 45 72 61 73 65 28 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b blic.void.Erase()..............{
a460 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 41 72 72 61 79 48 65 6c 70 65 72 73 2e 45 ..................ArrayHelpers.E
a480 72 61 73 65 41 74 28 72 65 66 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 raseAt(ref.m_ActionMap.m_Binding
a4a0 73 2c 20 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 s,.m_BindingIndex);.............
a4c0 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 43 6c 65 61 72 50 65 72 41 63 74 69 6f 6e 43 .....m_ActionMap.ClearPerActionC
a4e0 61 63 68 65 64 42 69 6e 64 69 6e 67 44 61 74 61 28 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 achedBindingData();.............
a500 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 4c 61 7a 79 52 65 73 6f 6c 76 65 42 69 6e 64 .....m_ActionMap.LazyResolveBind
a520 69 6e 67 73 28 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 20 57 65 ings();....................//.We
a540 20 68 61 76 65 20 73 77 69 74 63 68 65 64 20 74 6f 20 61 20 64 69 66 66 65 72 65 6e 74 20 62 69 .have.switched.to.a.different.bi
a560 6e 64 69 6e 67 20 61 72 72 61 79 2e 20 46 6f 72 20 73 69 6e 67 6c 65 74 6f 6e 20 61 63 74 69 6f nding.array..For.singleton.actio
a580 6e 73 2c 20 77 65 20 6e 65 65 64 20 74 6f 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 ns,.we.need.to..................
a5a0 2f 2f 20 73 79 6e 63 20 75 70 20 74 68 65 20 72 65 66 65 72 65 6e 63 65 20 74 68 61 74 20 74 68 //.sync.up.the.reference.that.th
a5c0 65 20 61 63 74 69 6f 6e 20 69 74 73 65 6c 66 20 68 61 73 2e 0d 0a 20 20 20 20 20 20 20 20 20 20 e.action.itself.has.............
a5e0 20 20 20 20 20 20 69 66 20 28 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 53 69 6e 67 6c 65 74 6f ......if.(m_ActionMap.m_Singleto
a600 6e 41 63 74 69 6f 6e 20 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 nAction.!=.null)................
a620 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 53 69 6e 67 6c 65 74 6f 6e 41 63 74 ......m_ActionMap.m_SingletonAct
a640 69 6f 6e 2e 6d 5f 53 69 6e 67 6c 65 74 6f 6e 41 63 74 69 6f 6e 42 69 6e 64 69 6e 67 73 20 3d 20 ion.m_SingletonActionBindings.=.
a660 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 69 6e 64 69 6e 67 73 3b 0d 0a 20 20 20 20 20 20 20 m_ActionMap.m_Bindings;.........
a680 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 74 65 72 6e 61 6c 20 42 .....}................internal.B
a6a0 69 6e 64 69 6e 67 53 79 6e 74 61 78 20 41 6e 64 20 3d 3e 20 74 68 72 6f 77 20 6e 65 77 20 4e 6f indingSyntax.And.=>.throw.new.No
a6c0 74 49 6d 70 6c 65 6d 65 6e 74 65 64 45 78 63 65 70 74 69 6f 6e 28 29 3b 0d 0a 20 20 20 20 20 20 tImplementedException();........
a6e0 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 74 72 75 63 74 20 43 6f 6d ..}............public.struct.Com
a700 70 6f 73 69 74 65 53 79 6e 74 61 78 0d 0a 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 positeSyntax..........{.........
a720 20 20 20 20 20 70 72 69 76 61 74 65 20 72 65 61 64 6f 6e 6c 79 20 49 6e 70 75 74 41 63 74 69 6f .....private.readonly.InputActio
a740 6e 20 6d 5f 41 63 74 69 6f 6e 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 72 69 76 61 74 65 n.m_Action;..............private
a760 20 72 65 61 64 6f 6e 6c 79 20 49 6e 70 75 74 41 63 74 69 6f 6e 4d 61 70 20 6d 5f 41 63 74 69 6f .readonly.InputActionMap.m_Actio
a780 6e 4d 61 70 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 72 69 76 61 74 65 20 69 6e 74 20 6d nMap;..............private.int.m
a7a0 5f 43 6f 6d 70 6f 73 69 74 65 49 6e 64 65 78 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 _CompositeIndex;................
a7c0 69 6e 74 65 72 6e 61 6c 20 43 6f 6d 70 6f 73 69 74 65 53 79 6e 74 61 78 28 49 6e 70 75 74 41 63 internal.CompositeSyntax(InputAc
a7e0 74 69 6f 6e 4d 61 70 20 6d 61 70 2c 20 49 6e 70 75 74 41 63 74 69 6f 6e 20 61 63 74 69 6f 6e 2c tionMap.map,.InputAction.action,
a800 20 69 6e 74 20 63 6f 6d 70 6f 73 69 74 65 49 6e 64 65 78 29 0d 0a 20 20 20 20 20 20 20 20 20 20 .int.compositeIndex)............
a820 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 20 3d 20 ..{..................m_Action.=.
a840 61 63 74 69 6f 6e 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f action;..................m_Actio
a860 6e 4d 61 70 20 3d 20 6d 61 70 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 43 nMap.=.map;..................m_C
a880 6f 6d 70 6f 73 69 74 65 49 6e 64 65 78 20 3d 20 63 6f 6d 70 6f 73 69 74 65 49 6e 64 65 78 3b 0d ompositeIndex.=.compositeIndex;.
a8a0 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 .............}................pu
a8c0 62 6c 69 63 20 43 6f 6d 70 6f 73 69 74 65 53 79 6e 74 61 78 20 57 69 74 68 28 73 74 72 69 6e 67 blic.CompositeSyntax.With(string
a8e0 20 6e 61 6d 65 2c 20 73 74 72 69 6e 67 20 62 69 6e 64 69 6e 67 2c 20 73 74 72 69 6e 67 20 67 72 .name,.string.binding,.string.gr
a900 6f 75 70 73 20 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 oups.=.null)..............{.....
a920 20 20 20 20 20 20 20 20 20 20 20 20 20 2f 2f 2f 2f 54 4f 44 4f 3a 20 63 68 65 63 6b 20 77 68 65 .............////TODO:.check.whe
a940 74 68 65 72 20 6e 6f 6e 2d 63 6f 6d 70 6f 73 69 74 65 20 62 69 6e 64 69 6e 67 73 20 68 61 76 65 ther.non-composite.bindings.have
a960 20 62 65 65 6e 20 61 64 64 65 64 20 69 6e 2d 62 65 74 77 65 65 6e 0d 0a 0d 0a 20 20 20 20 20 20 .been.added.in-between..........
a980 20 20 20 20 20 20 20 20 20 20 69 6e 74 20 62 69 6e 64 69 6e 67 49 6e 64 65 78 3b 0d 0a 20 20 20 ..........int.bindingIndex;.....
a9a0 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 5f 41 63 74 69 6f 6e 20 21 3d 20 6e 75 6c .............if.(m_Action.!=.nul
a9c0 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 69 6e 64 69 6e 67 49 l)......................bindingI
a9e0 6e 64 65 78 20 3d 20 6d 5f 41 63 74 69 6f 6e 2e 41 64 64 42 69 6e 64 69 6e 67 28 70 61 74 68 3a ndex.=.m_Action.AddBinding(path:
aa00 20 62 69 6e 64 69 6e 67 2c 20 67 72 6f 75 70 73 3a 20 67 72 6f 75 70 73 29 0d 0a 20 20 20 20 20 .binding,.groups:.groups).......
aa20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 2e 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 ....................m_BindingInd
aa40 65 78 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 65 6c 73 65 0d 0a 20 20 20 20 20 ex;..................else.......
aa60 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 62 69 6e 64 69 6e 67 49 6e 64 65 78 20 3d 20 6d 5f ...............bindingIndex.=.m_
aa80 41 63 74 69 6f 6e 4d 61 70 2e 41 64 64 42 69 6e 64 69 6e 67 28 70 61 74 68 3a 20 62 69 6e 64 69 ActionMap.AddBinding(path:.bindi
aaa0 6e 67 2c 20 67 72 6f 75 70 73 3a 20 67 72 6f 75 70 73 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 ng,.groups:.groups).............
aac0 20 20 20 20 20 20 20 20 20 20 20 20 20 2e 6d 5f 42 69 6e 64 69 6e 67 49 6e 64 65 78 3b 0d 0a 0d ..............m_BindingIndex;...
aae0 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e 6d 5f 42 .................m_ActionMap.m_B
ab00 69 6e 64 69 6e 67 73 5b 62 69 6e 64 69 6e 67 49 6e 64 65 78 5d 2e 6e 61 6d 65 20 3d 20 6e 61 6d indings[bindingIndex].name.=.nam
ab20 65 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 63 74 69 6f 6e 4d 61 70 2e e;..................m_ActionMap.
ab40 6d 5f 42 69 6e 64 69 6e 67 73 5b 62 69 6e 64 69 6e 67 49 6e 64 65 78 5d 2e 69 73 50 61 72 74 4f m_Bindings[bindingIndex].isPartO
ab60 66 43 6f 6d 70 6f 73 69 74 65 20 3d 20 74 72 75 65 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 fComposite.=.true;..............
ab80 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 ......return.this;..............
aba0 7d 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 73 }..........}............public.s
abc0 74 72 75 63 74 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 0d 0a 20 20 20 20 20 truct.ControlSchemeSyntax.......
abe0 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 72 69 76 61 74 65 20 72 65 61 64 6f 6e ...{..............private.readon
ac00 6c 79 20 49 6e 70 75 74 41 63 74 69 6f 6e 41 73 73 65 74 20 6d 5f 41 73 73 65 74 3b 0d 0a 20 20 ly.InputActionAsset.m_Asset;....
ac20 20 20 20 20 20 20 20 20 20 20 70 72 69 76 61 74 65 20 72 65 61 64 6f 6e 6c 79 20 69 6e 74 20 6d ..........private.readonly.int.m
ac40 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 49 6e 64 65 78 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 _ControlSchemeIndex;............
ac60 20 20 70 72 69 76 61 74 65 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 6d 5f 43 ..private.InputControlScheme.m_C
ac80 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 74 ontrolScheme;................int
aca0 65 72 6e 61 6c 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 28 49 6e 70 75 74 41 ernal.ControlSchemeSyntax(InputA
acc0 63 74 69 6f 6e 41 73 73 65 74 20 61 73 73 65 74 2c 20 69 6e 74 20 69 6e 64 65 78 29 0d 0a 20 20 ctionAsset.asset,.int.index)....
ace0 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 ..........{..................m_A
ad00 73 73 65 74 20 3d 20 61 73 73 65 74 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d sset.=.asset;..................m
ad20 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 49 6e 64 65 78 20 3d 20 69 6e 64 65 78 3b 0d 0a 20 20 _ControlSchemeIndex.=.index;....
ad40 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 3d 20 ..............m_ControlScheme.=.
ad60 6e 65 77 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 28 29 3b 0d 0a 20 20 20 20 20 new.InputControlScheme();.......
ad80 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 69 6e 74 65 72 6e 61 6c .......}................internal
ada0 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 28 49 6e 70 75 74 43 6f 6e 74 72 6f .ControlSchemeSyntax(InputContro
adc0 6c 53 63 68 65 6d 65 20 63 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 29 0d 0a 20 20 20 20 20 20 20 20 lScheme.controlScheme)..........
ade0 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 73 73 65 74 20 3d ....{..................m_Asset.=
ae00 20 6e 75 6c 6c 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 43 6f 6e 74 72 6f .null;..................m_Contro
ae20 6c 53 63 68 65 6d 65 49 6e 64 65 78 20 3d 20 2d 31 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 lSchemeIndex.=.-1;..............
ae40 20 20 20 20 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 3d 20 63 6f 6e 74 72 6f 6c 53 63 68 ....m_ControlScheme.=.controlSch
ae60 65 6d 65 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 eme;..............}.............
ae80 20 20 20 70 75 62 6c 69 63 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 20 57 69 ...public.ControlSchemeSyntax.Wi
aea0 74 68 42 69 6e 64 69 6e 67 47 72 6f 75 70 28 73 74 72 69 6e 67 20 62 69 6e 64 69 6e 67 47 72 6f thBindingGroup(string.bindingGro
aec0 75 70 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 up)..............{..............
aee0 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 62 69 6e ....if.(string.IsNullOrEmpty(bin
af00 64 69 6e 67 47 72 6f 75 70 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 dingGroup)).....................
af20 20 74 68 72 6f 77 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e .throw.new.ArgumentNullException
af40 28 6e 61 6d 65 6f 66 28 62 69 6e 64 69 6e 67 47 72 6f 75 70 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 (nameof(bindingGroup));.........
af60 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 5f 41 73 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 0d ...........if.(m_Asset.==.null).
af80 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 43 6f 6e 74 72 6f 6c 53 63 .....................m_ControlSc
afa0 68 65 6d 65 2e 6d 5f 42 69 6e 64 69 6e 67 47 72 6f 75 70 20 3d 20 62 69 6e 64 69 6e 67 47 72 6f heme.m_BindingGroup.=.bindingGro
afc0 75 70 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 65 6c 73 65 0d 0a 20 20 20 20 20 up;..................else.......
afe0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 73 73 65 74 2e 6d 5f 43 6f 6e 74 72 6f 6c ...............m_Asset.m_Control
b000 53 63 68 65 6d 65 73 5b 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 49 6e 64 65 78 5d 2e 62 69 Schemes[m_ControlSchemeIndex].bi
b020 6e 64 69 6e 67 47 72 6f 75 70 20 3d 20 62 69 6e 64 69 6e 67 47 72 6f 75 70 3b 0d 0a 0d 0a 20 20 ndingGroup.=.bindingGroup;......
b040 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 ..............return.this;......
b060 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 ........}................public.
b080 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 20 57 69 74 68 52 65 71 75 69 72 65 64 ControlSchemeSyntax.WithRequired
b0a0 44 65 76 69 63 65 3c 54 44 65 76 69 63 65 3e 28 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 Device<TDevice>()...............
b0c0 20 20 20 77 68 65 72 65 20 54 44 65 76 69 63 65 20 3a 20 49 6e 70 75 74 44 65 76 69 63 65 0d 0a ...where.TDevice.:.InputDevice..
b0e0 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 ............{..................r
b100 65 74 75 72 6e 20 57 69 74 68 52 65 71 75 69 72 65 64 44 65 76 69 63 65 28 44 65 76 69 63 65 54 eturn.WithRequiredDevice(DeviceT
b120 79 70 65 54 6f 43 6f 6e 74 72 6f 6c 50 61 74 68 3c 54 44 65 76 69 63 65 3e 28 29 29 3b 0d 0a 20 ypeToControlPath<TDevice>());...
b140 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c ...........}................publ
b160 69 63 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 20 57 69 74 68 4f 70 74 69 6f ic.ControlSchemeSyntax.WithOptio
b180 6e 61 6c 44 65 76 69 63 65 3c 54 44 65 76 69 63 65 3e 28 29 0d 0a 20 20 20 20 20 20 20 20 20 20 nalDevice<TDevice>()............
b1a0 20 20 20 20 20 20 77 68 65 72 65 20 54 44 65 76 69 63 65 20 3a 20 49 6e 70 75 74 44 65 76 69 63 ......where.TDevice.:.InputDevic
b1c0 65 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 e..............{................
b1e0 20 20 72 65 74 75 72 6e 20 57 69 74 68 4f 70 74 69 6f 6e 61 6c 44 65 76 69 63 65 28 44 65 76 69 ..return.WithOptionalDevice(Devi
b200 63 65 54 79 70 65 54 6f 43 6f 6e 74 72 6f 6c 50 61 74 68 3c 54 44 65 76 69 63 65 3e 28 29 29 3b ceTypeToControlPath<TDevice>());
b220 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 ..............}................p
b240 75 62 6c 69 63 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 20 4f 72 57 69 74 68 ublic.ControlSchemeSyntax.OrWith
b260 52 65 71 75 69 72 65 64 44 65 76 69 63 65 3c 54 44 65 76 69 63 65 3e 28 29 0d 0a 20 20 20 20 20 RequiredDevice<TDevice>().......
b280 20 20 20 20 20 20 20 20 20 20 20 77 68 65 72 65 20 54 44 65 76 69 63 65 20 3a 20 49 6e 70 75 74 ...........where.TDevice.:.Input
b2a0 44 65 76 69 63 65 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 Device..............{...........
b2c0 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 57 69 74 68 52 65 71 75 69 72 65 64 44 65 76 69 63 65 .......return.WithRequiredDevice
b2e0 28 44 65 76 69 63 65 54 79 70 65 54 6f 43 6f 6e 74 72 6f 6c 50 61 74 68 3c 54 44 65 76 69 63 65 (DeviceTypeToControlPath<TDevice
b300 3e 28 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 >());..............}............
b320 20 20 20 20 70 75 62 6c 69 63 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 20 4f ....public.ControlSchemeSyntax.O
b340 72 57 69 74 68 4f 70 74 69 6f 6e 61 6c 44 65 76 69 63 65 3c 54 44 65 76 69 63 65 3e 28 29 0d 0a rWithOptionalDevice<TDevice>()..
b360 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 77 68 65 72 65 20 54 44 65 76 69 63 65 20 3a 20 ................where.TDevice.:.
b380 49 6e 70 75 74 44 65 76 69 63 65 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 InputDevice..............{......
b3a0 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 57 69 74 68 4f 70 74 69 6f 6e 61 6c 44 ............return.WithOptionalD
b3c0 65 76 69 63 65 28 44 65 76 69 63 65 54 79 70 65 54 6f 43 6f 6e 74 72 6f 6c 50 61 74 68 3c 54 44 evice(DeviceTypeToControlPath<TD
b3e0 65 76 69 63 65 3e 28 29 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 evice>());..............}.......
b400 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e .........public.ControlSchemeSyn
b420 74 61 78 20 57 69 74 68 52 65 71 75 69 72 65 64 44 65 76 69 63 65 28 73 74 72 69 6e 67 20 63 6f tax.WithRequiredDevice(string.co
b440 6e 74 72 6f 6c 50 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 ntrolPath)..............{.......
b460 20 20 20 20 20 20 20 20 20 20 20 41 64 64 44 65 76 69 63 65 45 6e 74 72 79 28 63 6f 6e 74 72 6f ...........AddDeviceEntry(contro
b480 6c 50 61 74 68 2c 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e 44 65 76 69 63 65 lPath,.InputControlScheme.Device
b4a0 52 65 71 75 69 72 65 6d 65 6e 74 2e 46 6c 61 67 73 2e 4e 6f 6e 65 29 3b 0d 0a 20 20 20 20 20 20 Requirement.Flags.None);........
b4c0 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 20 ..........return.this;..........
b4e0 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 43 6f 6e 74 ....}................public.Cont
b500 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 20 57 69 74 68 4f 70 74 69 6f 6e 61 6c 44 65 76 69 rolSchemeSyntax.WithOptionalDevi
b520 63 65 28 73 74 72 69 6e 67 20 63 6f 6e 74 72 6f 6c 50 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 ce(string.controlPath)..........
b540 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 41 64 64 44 65 76 69 63 65 ....{..................AddDevice
b560 45 6e 74 72 79 28 63 6f 6e 74 72 6f 6c 50 61 74 68 2c 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 Entry(controlPath,.InputControlS
b580 63 68 65 6d 65 2e 44 65 76 69 63 65 52 65 71 75 69 72 65 6d 65 6e 74 2e 46 6c 61 67 73 2e 4f 70 cheme.DeviceRequirement.Flags.Op
b5a0 74 69 6f 6e 61 6c 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e tional);..................return
b5c0 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 .this;..............}...........
b5e0 20 20 20 20 20 70 75 62 6c 69 63 20 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 53 79 6e 74 61 78 20 .....public.ControlSchemeSyntax.
b600 4f 72 57 69 74 68 52 65 71 75 69 72 65 64 44 65 76 69 63 65 28 73 74 72 69 6e 67 20 63 6f 6e 74 OrWithRequiredDevice(string.cont
b620 72 6f 6c 50 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 rolPath)..............{.........
b640 20 20 20 20 20 20 20 20 20 41 64 64 44 65 76 69 63 65 45 6e 74 72 79 28 63 6f 6e 74 72 6f 6c 50 .........AddDeviceEntry(controlP
b660 61 74 68 2c 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e 44 65 76 69 63 65 52 65 ath,.InputControlScheme.DeviceRe
b680 71 75 69 72 65 6d 65 6e 74 2e 46 6c 61 67 73 2e 4f 72 29 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 quirement.Flags.Or);............
b6a0 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 ......return.this;..............
b6c0 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 43 6f 6e 74 72 6f 6c 53 }................public.ControlS
b6e0 63 68 65 6d 65 53 79 6e 74 61 78 20 4f 72 57 69 74 68 4f 70 74 69 6f 6e 61 6c 44 65 76 69 63 65 chemeSyntax.OrWithOptionalDevice
b700 28 73 74 72 69 6e 67 20 63 6f 6e 74 72 6f 6c 50 61 74 68 29 0d 0a 20 20 20 20 20 20 20 20 20 20 (string.controlPath)............
b720 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 41 64 64 44 65 76 69 63 65 45 6e ..{..................AddDeviceEn
b740 74 72 79 28 63 6f 6e 74 72 6f 6c 50 61 74 68 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 try(controlPath,................
b760 20 20 20 20 20 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e 44 65 76 69 63 65 52 ......InputControlScheme.DeviceR
b780 65 71 75 69 72 65 6d 65 6e 74 2e 46 6c 61 67 73 2e 4f 70 74 69 6f 6e 61 6c 20 7c 0d 0a 20 20 20 equirement.Flags.Optional.|.....
b7a0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 .................InputControlSch
b7c0 65 6d 65 2e 44 65 76 69 63 65 52 65 71 75 69 72 65 6d 65 6e 74 2e 46 6c 61 67 73 2e 4f 72 29 3b eme.DeviceRequirement.Flags.Or);
b7e0 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 74 68 69 73 3b 0d 0a ..................return.this;..
b800 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 72 69 ............}................pri
b820 76 61 74 65 20 73 74 72 69 6e 67 20 44 65 76 69 63 65 54 79 70 65 54 6f 43 6f 6e 74 72 6f 6c 50 vate.string.DeviceTypeToControlP
b840 61 74 68 3c 54 44 65 76 69 63 65 3e 28 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 ath<TDevice>()..................
b860 77 68 65 72 65 20 54 44 65 76 69 63 65 20 3a 20 49 6e 70 75 74 44 65 76 69 63 65 0d 0a 20 20 20 where.TDevice.:.InputDevice.....
b880 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 76 61 72 20 .........{..................var.
b8a0 6c 61 79 6f 75 74 4e 61 6d 65 20 3d 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 4c 61 79 6f 75 74 2e layoutName.=.InputControlLayout.
b8c0 73 5f 4c 61 79 6f 75 74 73 2e 54 72 79 46 69 6e 64 4c 61 79 6f 75 74 46 6f 72 54 79 70 65 28 74 s_Layouts.TryFindLayoutForType(t
b8e0 79 70 65 6f 66 28 54 44 65 76 69 63 65 29 29 2e 54 6f 53 74 72 69 6e 67 28 29 3b 0d 0a 20 20 20 ypeof(TDevice)).ToString();.....
b900 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 .............if.(string.IsNullOr
b920 45 6d 70 74 79 28 6c 61 79 6f 75 74 4e 61 6d 65 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 Empty(layoutName))..............
b940 20 20 20 20 20 20 20 20 6c 61 79 6f 75 74 4e 61 6d 65 20 3d 20 74 79 70 65 6f 66 28 54 44 65 76 ........layoutName.=.typeof(TDev
b960 69 63 65 29 2e 4e 61 6d 65 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 65 74 75 ice).Name;..................retu
b980 72 6e 20 24 22 3c 7b 6c 61 79 6f 75 74 4e 61 6d 65 7d 3e 22 3b 0d 0a 20 20 20 20 20 20 20 20 20 rn.$"<{layoutName}>";...........
b9a0 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 75 62 6c 69 63 20 49 6e 70 75 74 ...}................public.Input
b9c0 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 20 44 6f 6e 65 28 29 0d 0a 20 20 20 20 20 20 20 20 20 20 ControlScheme.Done()............
b9e0 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 5f 41 73 73 65 74 ..{..................if.(m_Asset
ba00 20 21 3d 20 6e 75 6c 6c 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 72 .!=.null)......................r
ba20 65 74 75 72 6e 20 6d 5f 41 73 73 65 74 2e 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 73 5b 6d eturn.m_Asset.m_ControlSchemes[m
ba40 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 49 6e 64 65 78 5d 3b 0d 0a 20 20 20 20 20 20 20 20 20 _ControlSchemeIndex];...........
ba60 20 20 20 20 20 20 20 72 65 74 75 72 6e 20 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 3b 0d 0a .......return.m_ControlScheme;..
ba80 20 20 20 20 20 20 20 20 20 20 20 20 7d 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 70 72 69 ............}................pri
baa0 76 61 74 65 20 76 6f 69 64 20 41 64 64 44 65 76 69 63 65 45 6e 74 72 79 28 73 74 72 69 6e 67 20 vate.void.AddDeviceEntry(string.
bac0 63 6f 6e 74 72 6f 6c 50 61 74 68 2c 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e controlPath,.InputControlScheme.
bae0 44 65 76 69 63 65 52 65 71 75 69 72 65 6d 65 6e 74 2e 46 6c 61 67 73 20 66 6c 61 67 73 29 0d 0a DeviceRequirement.Flags.flags)..
bb00 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 69 ............{..................i
bb20 66 20 28 73 74 72 69 6e 67 2e 49 73 4e 75 6c 6c 4f 72 45 6d 70 74 79 28 63 6f 6e 74 72 6f 6c 50 f.(string.IsNullOrEmpty(controlP
bb40 61 74 68 29 29 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 74 68 72 6f 77 ath))......................throw
bb60 20 6e 65 77 20 41 72 67 75 6d 65 6e 74 4e 75 6c 6c 45 78 63 65 70 74 69 6f 6e 28 6e 61 6d 65 6f .new.ArgumentNullException(nameo
bb80 66 28 63 6f 6e 74 72 6f 6c 50 61 74 68 29 29 3b 0d 0a 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 f(controlPath));................
bba0 20 20 20 20 76 61 72 20 73 63 68 65 6d 65 20 3d 20 6d 5f 41 73 73 65 74 20 21 3d 20 6e 75 6c 6c ....var.scheme.=.m_Asset.!=.null
bbc0 20 3f 20 6d 5f 41 73 73 65 74 2e 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 73 5b 6d 5f 43 6f .?.m_Asset.m_ControlSchemes[m_Co
bbe0 6e 74 72 6f 6c 53 63 68 65 6d 65 49 6e 64 65 78 5d 20 3a 20 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 ntrolSchemeIndex].:.m_ControlSch
bc00 65 6d 65 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 41 72 72 61 79 48 65 6c 70 65 eme;..................ArrayHelpe
bc20 72 73 2e 41 70 70 65 6e 64 28 72 65 66 20 73 63 68 65 6d 65 2e 6d 5f 44 65 76 69 63 65 52 65 71 rs.Append(ref.scheme.m_DeviceReq
bc40 75 69 72 65 6d 65 6e 74 73 2c 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 uirements,......................
bc60 6e 65 77 20 49 6e 70 75 74 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 2e 44 65 76 69 63 65 52 65 71 new.InputControlScheme.DeviceReq
bc80 75 69 72 65 6d 65 6e 74 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7b 0d uirement......................{.
bca0 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 43 6f 6e 74 72 .........................m_Contr
bcc0 6f 6c 50 61 74 68 20 3d 20 63 6f 6e 74 72 6f 6c 50 61 74 68 2c 0d 0a 20 20 20 20 20 20 20 20 20 olPath.=.controlPath,...........
bce0 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 46 6c 61 67 73 20 3d 20 66 6c 61 67 73 2c 0d ...............m_Flags.=.flags,.
bd00 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 7d 29 3b 0d 0a 0d 0a 20 20 20 20 .....................});........
bd20 20 20 20 20 20 20 20 20 20 20 20 20 69 66 20 28 6d 5f 41 73 73 65 74 20 3d 3d 20 6e 75 6c 6c 29 ............if.(m_Asset.==.null)
bd40 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 43 6f 6e 74 72 6f 6c 53 ......................m_ControlS
bd60 63 68 65 6d 65 20 3d 20 73 63 68 65 6d 65 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 cheme.=.scheme;.................
bd80 20 65 6c 73 65 0d 0a 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 6d 5f 41 73 73 .else......................m_Ass
bda0 65 74 2e 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 65 6d 65 73 5b 6d 5f 43 6f 6e 74 72 6f 6c 53 63 68 et.m_ControlSchemes[m_ControlSch
bdc0 65 6d 65 49 6e 64 65 78 5d 20 3d 20 73 63 68 65 6d 65 3b 0d 0a 20 20 20 20 20 20 20 20 20 20 20 emeIndex].=.scheme;.............
bde0 20 7d 0d 0a 20 20 20 20 20 20 20 20 7d 0d 0a 20 20 20 20 7d 0d 0a 7d 0d 0a 00 00 00 00 00 00 00 .}..........}......}..}.........
be00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 49 6e 70 75 74 41 63 74 69 6f 6e 53 ....................InputActionS
be20 65 74 75 70 45 78 74 65 6e 73 69 6f 6e 73 00 00 17 00 00 00 55 6e 69 74 79 45 6e 67 69 6e 65 2e etupExtensions......UnityEngine.
be40 49 6e 70 75 74 53 79 73 74 65 6d 00 InputSystem.