|
|
(One intermediate revision by one other user not shown) |
Line 1: |
Line 1: |
| {{Command|= Comments
| | #REDIRECT [[-]] |
| ____________________________________________________________________________________________
| |
| | |
| | ofp |= Game name
| |
| | |
| |1.00|= Game version
| |
| ____________________________________________________________________________________________
| |
| | |
| | Subtracts '''b''' from '''a'''. '''a''' and '''b''' need to be of the same type, both [[Number]]s or both [[Array]]s. In Arma 3 it is possible to subtract nested arrays. |= Description
| |
| ____________________________________________________________________________________________
| |
| | |
| | a '''-''' b |= Syntax
| |
| | |
| |p1 = a: [[Number]] or [[Array]]
| |
| | |
| |p2 = b: [[Number]] or [[Array]]
| |
| | |
| | [[Number]] or [[Array]] |= Return value
| |
| ____________________________________________________________________________________________
| |
| |x1 = For numbers: <code>_sum = 10 - 7; //_sum is 3</code>|=
| |
| | |
| |x2 = For arrays: contents of array '''b''' removed from array '''a'''. Returns new array.<code>_result = [1, 2, 2, [[player]], "String"] - [2, [[player]], [[player]], "String"]; //_result is [1]</code>|=
| |
| | |
| |x3 = Compare:<code>[0,[0],<nowiki>[</nowiki>[0]]] - [0]; //<nowiki>[</nowiki>[0],<nowiki>[</nowiki>[0]]]
| |
| [0,[0],<nowiki>[</nowiki>[0]]] - <nowiki>[</nowiki>[0]]; //[0,<nowiki>[</nowiki>[0]]] - Arma 3 only
| |
| [0,[0],<nowiki>[</nowiki>[0]]] - <nowiki>[</nowiki><nowiki>[</nowiki>[0]]]; //[0,[0]] - Arma 3 only</code>|=
| |
| | |
| | [[Array]], [[Operators]] |= See also
| |
| | |
| }}
| |
| | |
| <h3 style="display:none">Notes</h3>
| |
| <dl class="command_description">
| |
| <!-- Note Section BEGIN -->
| |
| | |
| <!-- Note Section END -->
| |
| </dl>
| |
| | |
| <h3 style="display:none">Bottom Section</h3>
| |
| | |
| [[Category:Scripting Commands|#]]
| |
| [[Category:Scripting Commands OFP 1.99|#]]
| |
| [[Category:Scripting Commands OFP 1.96|#]]
| |
| [[Category:Scripting Commands OFP 1.46|#]]
| |
| [[Category:Scripting Commands ArmA|#]]
| |
| [[Category:Scripting Commands ArmA2|#]]
| |
| [[Category:Arma 3: Scripting Commands]]
| |
| [[Category:Command Group: Math|#]]
| |
| [[Category:Command Group: Variables|#]]
| |
| [[Category:Notes: Improper Formatting|{{uc:{{PAGENAME}}}}]]
| |