Forráskód Böngészése

Update camera manual for en/ru with new function. (#392)

Kharkunov Eugene 1 éve
szülő
commit
6b5a84fce0
2 módosított fájl, 12 hozzáadás és 2 törlés
  1. 6 1
      docs/en/manuals/camera.md
  2. 6 1
      docs/ru/manuals/camera.md

+ 6 - 1
docs/en/manuals/camera.md

@@ -51,7 +51,12 @@ Orthographic Zoom
 
 ## Using the camera
 
-To activate a camera and have it feed its view and projection matrices to the render script, you send the component an `acquire_camera_focus` message:
+To activate a camera and have it feed its view and projection matrices to the render script, you call `camera.acquire_focus` or send the component an `acquire_camera_focus` message:
+
+```lua
+camera.acquire_focus("#camera")
+```
+or
 
 ```lua
 msg.post("#camera", "acquire_camera_focus")

+ 6 - 1
docs/ru/manuals/camera.md

@@ -37,7 +37,12 @@ Auto Aspect Ratio
 
 ## Использование камеры
 
-Чтобы активировать камеру и передать ее матрицы вида и проекции в рендер-скрипт, компоненту посылается сообщение acquire_camera_focus:
+Чтобы активировать камеру и передать ее матрицы вида и проекции в рендер-скрипт, нужно вызвать функцию `camera.acquire_focus` или отправить компоненту сообщение acquire_camera_focus:
+
+```lua
+camera.acquire_focus("#camera")
+```
+или
 
 ```lua
 msg.post("#camera", "acquire_camera_focus")