setDefaultCamera: Difference between revisions
Jump to navigation
Jump to search
m (format) |
m (template:command argument fix) |
||
Line 7: | Line 7: | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| Sets the position and direction for the camera used after camera is set on no object (log out view when leaving MP game for example) |= | | Sets the position and direction for the camera used after camera is set on no object (log out view when leaving MP game for example) |DESCRIPTION= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| '''setDefaultCamera''' [position, direction] |= | | '''setDefaultCamera''' [position, direction] |SYNTAX= | ||
|p1= position: [[PositionASL]] - position of the camera |= | |p1= position: [[PositionASL]] - position of the camera |PARAMETER1= | ||
|p2= direction: [[Array]] - format [[Vector3D]] - direction of the camera |= | |p2= direction: [[Array]] - format [[Vector3D]] - direction of the camera |PARAMETER2= | ||
| [[Nothing]] |= | | [[Nothing]] |RETURNVALUE= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
|x1= <code>[[setDefaultCamera]] [[5000,5000,200],[1,1,-1]];</code> |= | |x1= <code>[[setDefaultCamera]] [[5000,5000,200],[1,1,-1]];</code> |EXAMPLE1= | ||
|x2= Lift camera 100m up above current player position and point downwards: | |x2= Lift camera 100m up above current player position and point downwards: | ||
<code>[[setDefaultCamera]] <nowiki>[</nowiki>[[ATLtoASL]] ([[player]] [[modelToWorld]] [0,0,100]),[0,0,-1]];</code> |= | <code>[[setDefaultCamera]] <nowiki>[</nowiki>[[ATLtoASL]] ([[player]] [[modelToWorld]] [0,0,100]),[0,0,-1]];</code> |EXAMPLE2= | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| [[camCreate]], [[cameraOn]], [[cameraView]], [[cameraEffect]], [[cameraEffectEnableHUD]], [[switchCamera]], [[positionCameraToWorld]], [[cameraInterest]], [[setCameraInterest]], [[getEditorCamera]], [[mapCenterOnCamera]], [[preloadCamera]], [[restartEditorCamera]] |= | | [[camCreate]], [[cameraOn]], [[cameraView]], [[cameraEffect]], [[cameraEffectEnableHUD]], [[switchCamera]], [[positionCameraToWorld]], [[cameraInterest]], [[setCameraInterest]], [[getEditorCamera]], [[mapCenterOnCamera]], [[preloadCamera]], [[restartEditorCamera]] |SEEALSO= | ||
}} | }} |
Revision as of 14:47, 7 April 2019
Description
- Description:
- Sets the position and direction for the camera used after camera is set on no object (log out view when leaving MP game for example)
- Groups:
- Uncategorised
Syntax
- Syntax:
- setDefaultCamera [position, direction]
- Parameters:
- position: PositionASL - position of the camera
- direction: Array - format Vector3D - direction of the camera
- Return Value:
- Nothing
Examples
- Example 1:
setDefaultCamera [[5000,5000,200],[1,1,-1]];
- Example 2:
- Lift camera 100m up above current player position and point downwards:
setDefaultCamera [ATLtoASL (player modelToWorld [0,0,100]),[0,0,-1]];
Additional Information
- See also:
- camCreatecameraOncameraViewcameraEffectcameraEffectEnableHUDswitchCamerapositionCameraToWorldcameraInterestsetCameraInterestgetEditorCameramapCenterOnCamerapreloadCamerarestartEditorCamera
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note