enenra / space-engineers-utilities

A Blender 4.0+ addon to streamline working on assets for Space Engineers.
https://spaceengineers.wiki.gg/wiki/Modding/Tools/Space_Engineers_Utilities
GNU General Public License v3.0
47 stars 12 forks source link

SolarPanel <Pivots> generated from empties #399

Open THDigi opened 4 months ago

THDigi commented 4 months ago

SE v204 added <Pivots> to solar panel definitions which allows modders to define where the rays come from and how many of them.

This suggestion is to generate that tag from model empties to be easier to visualize (especially as the new F11 solar panels draw isn't that useful).

Example of the tag, more in CubeBlocks_DecorativePack3.sbc.

<Pivots>
  <Vector3>
    <X>-0.5</X>
    <Y>0</Y>
    <Z>0</Z>
  </Vector3>
  <Vector3>
    <X>-0.5</X>
    <Y>0</Y>
    <Z>-0.5</Z>
  </Vector3>
  ... etc
</Pivots>

Units are in cell sizes (gets multiplied by grid size in meters on load) and floating point as you can see so it's not limited to the center of a cell.

THDigi commented 4 months ago

Z is flipped btw, positive values offset towards forward not backward 😒