User Tools

Site Tools


add_object

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
add_object [2020/04/22 17:28] justinadd_object [2020/06/07 17:26] justin
Line 2: Line 2:
 ---- ----
  
-Adds an [[object]] to the specified [[tile]] within the [[map]] (if the [[tile]] is not already occupied by another [[object]]). The [[entity]] ID is optional and will be assigned to the new [[object]] if supplied.+Adds an [[object|object]] to the specified [[tile|tile]] within the [[map|map]] (if the [[tile|tile]] is not already occupied by another [[object|object]]). The [[entity|entity]] ID is optional and will be assigned to the new [[object|object]] if supplied.
  
 ====Signature:==== ====Signature:====
Line 10: Line 10:
  
 ^Argument^Description^Type^Required^ ^Argument^Description^Type^Required^
-|model_name|Model to use for the new [[object]].|[[String]]|Yes| +|model_name|Model to use for the new [[object|object]].|[[string|String]]|Yes| 
-|tile|ID or [[coordinate]] of the [[tile]] where the [[object]] will be placed.|[[String]] or [[Coordinate]]|Yes| +|tile|ID or [[coordinate|coordinate]] of the [[tile|tile]] where the [[object|object]] will be placed.|[[string|String]][[coordinate|Coordinate]]|Yes| 
-|entity_id|Unique [[entity]] ID that will be assigned.|[[String]]|No|+|entity_id|Unique [[entity|entity]] ID that will be assigned.|[[string|String]]|No|
  
 <WRAP center round info 100%> <WRAP center round info 100%>
-The [[Remove Entity]] function can be triggered later to remove an [[object]] that was previously added to the scene with the Add Object function.+The [[remove_entity|Remove Entity]] function can be triggered later to remove an [[object|object]] that was previously added to the scene with the Add Object function.
 </WRAP> </WRAP>
  
Line 22: Line 22:
 add_object("tree_small", "target_tile", "new_tree") add_object("tree_small", "target_tile", "new_tree")
 </code> </code>
-//Results:// A small tree will be added to the [[map]] on the [[tile]] having ID "target_tile" and will be assigned an ID of "new_tree".+//Results:// A small tree will be added to the [[map|map]] on the [[tile|tile]] having ID "target_tile" and will be assigned an ID of "new_tree".
  
 <WRAP center round tip 100%> <WRAP center round tip 100%>
-Use the **Add Object** function to introduce new interactable [[object|objects]] or obstacles into the scene. After being added, you can use the [[Set Entity Script]] function to assign a [[script]] to the [[object]] or the [[Modify Navigation]] function to mark a now blocked path as impassable.+Use the **Add Object** function to introduce new interactable [[object|objects]] or obstacles into the scene. After being added, you can use the [[set_entity_script|Set Entity Script]] function to assign a [[script|script]] to the [[object|object]] or the [[modify_navigation|Modify Navigation]] function to mark a now blocked path as impassable.
 </WRAP> </WRAP>
  
Line 33: Line 33:
 <WRAP half column> <WRAP half column>
 ====Editor Node:==== ====Editor Node:====
-{{:wiki:add_object_node.png?nolink|}}+{{:add_object_node.png?nolink|}}
 </WRAP> </WRAP>
  
 <WRAP half column> <WRAP half column>
 ====Visual Demo:==== ====Visual Demo:====
-{{:wiki:add_object_demo.gif?nolink|}}+{{:add_object_demo.gif?nolink|}}
 </WRAP> </WRAP>
 </WRAP> </WRAP>
  
 ~~NOTOC~~ ~~NOTOC~~
add_object.txt · Last modified: 2023/01/02 21:15 by justin