RigsOfRods / rigs-of-rods

Main development repository for Rigs of Rods soft-body physics simulator
https://www.rigsofrods.org
GNU General Public License v3.0
990 stars 175 forks source link

AngelScript: new script 'example_ImGui_nodeHighlight.as' #3155

Closed ohlidalp closed 1 month ago

ohlidalp commented 1 month ago

obrazek Showcases existing and new API to get node info.

EXISTING:

* actor.getNodeCount()
* actor.getWheelNodeCount()
* actor.getNodePosition(int nodenum)

NEW:

* actor.isNodeWheelRim(int nodenum)
* actor.isNodeWheelTire(int nodenum)
ohlidalp commented 1 month ago

I added node selecting with mouse (LMB click to select/unselect). This is only in the script, the game doesn't know about it at all.

obrazek