Difference between revisions of "API ConfigureMultipleWeaponGroups"
From Vendetta Lua
(split) |
|||
Line 1: | Line 1: | ||
− | + | {{Function | |
− | + | | name = ConfigureMultipleWeaponGroups | |
− | + | | desc = configures weapon groups according to given tables. | |
− | + | | arg1_name = | |
− | + | | arg1_type = table | |
− | + | | arg1_desc = {table group1key1, table group1key2 ... table group1key6, table group2key1, table group2key2...}<br/> | |
− | + | ''group*key*'' Each table represents one group key. Key 1-6 map to the primary trigger, 7-12 secondary and 13-18 tertiary. Each index in the tables represents a port. Weapon ports start at index 2. Valid values for each port are nil or true. | |
− | + | | arg1_opt = | |
− | ''group*key*'' Each table represents one group key. Key 1-6 map to the primary trigger, 7-12 secondary and 13-18 tertiary. Each index in the tables represents a port. Weapon ports start at index 2. Valid values for each port are nil or true. | + | | arg2_name = cb |
− | + | | arg2_type = function | |
− | + | | arg2_desc = function to call on completion | |
− | '''Example:'''<br> | + | | arg2_opt = true |
+ | | ret1_type = nil | ||
+ | | notes = '''Example:'''<br> | ||
<source lang=lua> | <source lang=lua> | ||
-- enable port 1 for the primary trigger and port 2 for the secondary | -- enable port 1 for the primary trigger and port 2 for the secondary | ||
Line 16: | Line 18: | ||
ConfigureMultipleWeaponGroups{[1]={nil, true, nil}, [2]={nil, nil, true}} | ConfigureMultipleWeaponGroups{[1]={nil, true, nil}, [2]={nil, nil, true}} | ||
</source> | </source> | ||
+ | }} |
Latest revision as of 03:35, 19 October 2011
ConfigureMultipleWeaponGroups
Type | Name | Description |
---|---|---|
table | {table group1key1, table group1key2 ... table group1key6, table group2key1, table group2key2...} group*key* Each table represents one group key. Key 1-6 map to the primary trigger, 7-12 secondary and 13-18 tertiary. Each index in the tables represents a port. Weapon ports start at index 2. Valid values for each port are nil or true. | |
function | cb | function to call on completion (optional) |
Type | Name | Description |
---|---|---|
nil |
-- enable port 1 for the primary trigger and port 2 for the secondary -- index 1 is the power cell port ConfigureMultipleWeaponGroups{[1]={nil, true, nil}, [2]={nil, nil, true}}