Difference between revisions of "BIS fnc respect"

From Bohemia Interactive Community
Jump to navigation Jump to search
(Page filling - missing example)
m (Fix faction link)
 
Line 22: Line 22:
 
* "MODIFY" - change given respect value
 
* "MODIFY" - change given respect value
 
** param1: [[Object]] - unit of which respect value will be changed
 
** param1: [[Object]] - unit of which respect value will be changed
** param2: [[String]] - [[Faction|faction]] of which respect will be changed
+
** param2: [[String]] - [[faction]] of which respect will be changed
 
** param3: [[String]] - [[Code|code]] which defines formula for change (current respect value is stored in variable _r) - e.g. "_r / 2"
 
** param3: [[String]] - [[Code|code]] which defines formula for change (current respect value is stored in variable _r) - e.g. "_r / 2"
 
* "KILLED" - modify global town respect after civilian has been killed
 
* "KILLED" - modify global town respect after civilian has been killed

Latest revision as of 15:19, 4 June 2018

Introduced with Arma 2 version1.00
  

Click on the images for descriptions

Introduced in

Game:
Arma 2
Version:
1.00

Description

Description:
RESpect - The Effective Calculation Process.

Syntax

Syntax:
[mode, param1, param2, param3] call BIS_fnc_respect
Parameters:
mode: String - case-sensitive, can be one of "SET", "ADD", "MODIFY", "KILLED"
depending on mode:
  • "SET" - set respect default values
  • "ADD" - add respect values depending on global town respect
    • param1: Object - unit to which is given respect from assigned town with random difference defined in third argument
    • param2: Number - range of random difference
  • "MODIFY" - change given respect value
    • param1: Object - unit of which respect value will be changed
    • param2: String - faction of which respect will be changed
    • param3: String - code which defines formula for change (current respect value is stored in variable _r) - e.g. "_r / 2"
  • "KILLED" - modify global town respect after civilian has been killed
Return Value:
  • "SET": Array with zero respect values (if Object is passed as argument, 1 is on place of object's faction)
  • "ADD": unit's respect values
  • "MODIFY": modified respect value
  • "KILLED": modified town respect value

Examples

Example 1:
Example needed

Additional Information

Execution:
call
Multiplayer:
-
See also:
addRatingAmbient Civilians

Notes

Only post proven facts here. Report bugs on the feedback tracker. Use the talk page or the forums for discussions.
Add New Note | How To

Notes

Bottom Section