User Tools

Site Tools


mario_golf:hole_components

Differences

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

Link to this comparison view

mario_golf:hole_components [2020/08/17 20:17]
DeathBasket created
mario_golf:hole_components [2020/08/18 22:45] (current)
DeathBasket Typos, add link to geometry setup in encoding section
Line 12: Line 12:
  
 The function to load the majority of these components is: The function to load the majority of these components is:
-  loadHoleComponent(int holeNumber, int courseNumber,​ int componentNumber) // 0x80251DFC (US version)+  ​void loadHoleComponent(int holeNumber, int courseNumber,​ int componentNumber) // 0x80251DFC (US version)
 Where ''​componentNumber''​ takes values: Where ''​componentNumber''​ takes values:
   1 - geometry 1   1 - geometry 1
Line 20: Line 20:
   5 - ground type map   5 - ground type map
  
-Where coordinates are listed as shorts (geometry), the bounds of the hole are 0x1000x, 0x2000z. Where coordinated ​are listed as ints (pins, tees), the bounds of the hole are 0x400000x, 0x800000z. To scale between the systems, shift left or right by 10 bits as appropriate.+Where coordinates are listed as shorts (geometry), the bounds of the hole are 0x1000x, 0x2000z. Where coordinates ​are listed as ints (pins, tees), the bounds of the hole are 0x400000x, 0x800000z. To scale between the systems, shift left or right by 10 bits as appropriate.
  
 ====== Geometry ====== ====== Geometry ======
Line 94: Line 94:
   +0200z   +0200z
   repeat until  0f80x, 1f80z   repeat until  0f80x, 1f80z
-[todolink to code example when I upload one at some point...]+For an example, see [[https://github.com/​az64/​mg64lib/​blob/​master/​GameData/​DefaultGeometry.cs|here]].
  
 ====== Trees ====== ====== Trees ======
Line 111: Line 111:
 Tree types [[mario_golf:​object_type_list|here]]. Tree types [[mario_golf:​object_type_list|here]].
  
-Note that data is this file is not aligned.+Note that data in this file is not aligned.
  
 ====== Initial hole conditions ====== ====== Initial hole conditions ======
mario_golf/hole_components.txt ยท Last modified: 2020/08/18 22:45 by DeathBasket