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

Minor corrections and updates to manuals: collection proxy, facebook, particlefx, project settings and render.

Mikael Säker 7 éve
szülő
commit
ba575a7d2a

+ 2 - 2
docs/en/manuals/collection-proxy.md

@@ -29,7 +29,7 @@ When the Defold engine starts it loads and instanciates all game objects from a
 
 To fit the game objects and their components the engine allocates the memory needed for the whole "game world" into which the contents of the bootstrap collection are instanciated. A separate physics world is also created for any collision objects and physics simulation.
 
-Since script components need to be able to address all objects in the game, even from outside the bootstrap world, it is given a unique name: the *Id* property that you set in the collection file:
+Since script components need to be able to address all objects in the game, even from outside the bootstrap world, it is given a unique name: the *Name* property that you set in the collection file:
 
 ![bootstrap](images/collection-proxy/collection_id.png){srcset="images/collection-proxy/[email protected] 2x"}
 
@@ -48,7 +48,7 @@ msg.post("#myproxy", "load")
 
 The proxy component will instruct the engine to allocate space for a new world. A separate runtime physics world is also created and all the game objects in the collection "mylevel.collection" are instantiated.
 
-The new world gets its name from the *Id* property in the collection file, in this example it is set to "mylevel". The name has to be unique. If the *Id* set in the collection file is already used for a loaded world, the engine will signal a name collision error:
+The new world gets its name from the *Name* property in the collection file, in this example it is set to "mylevel". The name has to be unique. If the *Name* set in the collection file is already used for a loaded world, the engine will signal a name collision error:
 
 ```txt
 ERROR:GAMEOBJECT: The collection 'default' could not be created since there is already a socket with the same name.

+ 0 - 4
docs/en/manuals/facebook.md

@@ -9,10 +9,6 @@ The Facebook API allows you to interact with Facebook's game connectivity featur
 
 The Defold Facebook API brings the various platform specific Facebook APIs under a unified set of functions that work the same on iOS, Android and HTML5 (through Facebook Canvas). To get started with Facebook connectivity in your games, you need a Facebook account.
 
-::: important
-As of Defold 1.2.92, the Facebook API is redesigned with a new way of interacting with Facebook. The previous API still works, no breaking changes were introduced. However, the old API should be considered deprecated and not used in new applications.
-:::
-
 ## Registering as a Facebook developer
 
 To develop for Facebook you must sign up as a Facebook developer. This allows you to create Facebook applications that your Defold game can communicate with.

+ 1 - 1
docs/en/manuals/particlefx.md

@@ -77,7 +77,7 @@ Start Delay
 : The number of seconds the emitter should wait before emitting particles.
 
 Start Offset
-: The number of seconds into the particle simulation the emitter should start.
+: The number of seconds into the particle simulation the emitter should start, or in other words how long the emitter should pre-warm the effect for.
 
 Image
 : The image file (Tile source or Atlas) to use for texturing and animating the particles.

+ 7 - 3
docs/en/manuals/project-settings.md

@@ -432,8 +432,12 @@ When the engine starts, it is possible to provide config values from the command
 # Specify a bootstap collection
 $ dmengine --config=bootstrap.main_collection=/my.collectionc
 
-# Set the custom value "test.my_value"
-$ dmengine --config=test.my_value=4711
+# Set two custom config values
+$ dmengine --config=test.my_value=4711 --config=test2.my_value2=1234
 ```
 
-Custom values can---just like any other config value---be read with [`sys.get_config()`](/ref/sys/#sys.get_config).
+Custom values can---just like any other config value---be read with [`sys.get_config()`](/ref/sys/#sys.get_config):
+
+```lua
+local my_value = tonumber(sys.get_config("test.my_value")) 
+```

+ 3 - 3
docs/en/manuals/render.md

@@ -161,7 +161,7 @@ on_message()
 `"window_resized"`
 : The engine will send this message on changes of the window size. You can listen to this message to alter rendering when the target window size changes. On desktop this means that the actual game window has been resized and on mobile devices this message is sent whenever an orientation change happens.
 
-  ```
+  ```lua
   function on_message(self, message_id, message)
     if message_id == hash("window_resized") then
       -- The window was resized. message.width and message.height contain the new dimensions.
@@ -173,7 +173,7 @@ on_message()
 `"draw_line"`
 : Draw debug line. Use to visualize ray_casts, vectors and more. Lines are drawn with the `render.draw_debug3d()` call.
   
-  ```
+  ```lua
   -- draw a white line
   local p1 = vmath.vector3(0, 0, 0)
   local p2 = vmath.vector3(1000, 1000, 0)
@@ -184,7 +184,7 @@ on_message()
 `"draw_text"`
 : Draw debug text. Use to print debug information. The text is drawn with the built in "system_font" font. The system font has a material with tag "text" and is rendered with other text in the default render script.
   
-  ```
+  ```lua
   -- draw a text message
   local pos = vmath.vector3(500, 500, 0)
   msg.post("@render:", "draw_text", { text = "Hello world!", position = pos })