User Tools

Site Tools


besiege:modding:example-guides:creatingblock

Differences

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

Link to this comparison view

Both sides previous revision Previous revision
besiege:modding:example-guides:creatingblock [2018/07/10 16:17]
spaar [Getting Started]
besiege:modding:example-guides:creatingblock [2018/07/10 16:19] (current)
spaar
Line 16: Line 16:
 This will create a basic XML file and add a reference to it to the manifest. This will create a basic XML file and add a reference to it to the manifest.
  
-===== Defining the block'​s ​basic properties =====+===== Defining the block'​s properties =====
  
 The various elements of the block'​s XML file are used to define how the block behaves and looks in-game. For a full reference, see [[..:​xml-elements:​Block|Elements of a Block]]. The various elements of the block'​s XML file are used to define how the block behaves and looks in-game. For a full reference, see [[..:​xml-elements:​Block|Elements of a Block]].
  
-  * Assigning an ID+=== Assigning an ID ===
  
 The ID must uniquely identify the block among all blocks in the same mod; the easiest way to handle this is to just use sequential ID (1, 2, 3, ...). The ID must uniquely identify the block among all blocks in the same mod; the easiest way to handle this is to just use sequential ID (1, 2, 3, ...).
Line 26: Line 26:
 <code xml><​ID>​1</​ID></​code>​ <code xml><​ID>​1</​ID></​code>​
  
-  * Some basic properties+=== Some basic properties ​===
  
 <code xml> <code xml>
Line 33: Line 33:
 </​code>​ </​code>​
  
-===== Defining the block'​s visuals =====+=== Visuals ​===
  
 The visuals of a block are defined using the ''​Mesh''​ and ''​Texture''​ elements. They are used with the resource system, which means they first need to be defined in the mod manifest. The visuals of a block are defined using the ''​Mesh''​ and ''​Texture''​ elements. They are used with the resource system, which means they first need to be defined in the mod manifest.
Line 65: Line 65:
 There is an additional option to transform the mesh in case it is incorrectly positioned, rotated or scaled, see [[..:​xml-elements:​Common#​mesh|Mesh]]. There is an additional option to transform the mesh in case it is incorrectly positioned, rotated or scaled, see [[..:​xml-elements:​Common#​mesh|Mesh]].
  
-===== Colliders and Adding Points ​=====+=== Colliders and Adding Points ===
  
 Every block needs to have colliders for physics, as well as a base adding point which is used to place it on other blocks. Every block needs to have colliders for physics, as well as a base adding point which is used to place it on other blocks.
besiege/modding/example-guides/creatingblock.txt ยท Last modified: 2018/07/10 16:19 by spaar