Hodo33 Posted April 6, 2018 Share Posted April 6, 2018 I want to get access to the node points on a decal road so my aivehicle will path along the road. After looking at the c++ code I find this jeweldSprintf( buffer, 1024, "Node = \"%f %f %f %f\";", node.point.x, node.point.y, node.point.z, node.width ); It prints the node points in the mission file but no way to index them. I can add the index to this printout but not sure how to expose the node array to script. Any ideas there ? Quote Link to comment Share on other sites More sharing options...
irei1as Posted April 9, 2018 Share Posted April 9, 2018 You can usePoint3F DecalRoad::getNodePosition( U32 idx )instead.It's also located in decalRoad.cpp. Then you only need to show it to TorqueScript with a DefineEngineMethod.If you don't want to change the engine you could also create a Path and add various Marker to it that follows the decal road and just use those instead of the decal road.The downside of doing that is that you have to make two roads (the graphical one of decal road and the script one with markers). Quote Link to comment Share on other sites More sharing options...
Hodo33 Posted April 23, 2018 Author Share Posted April 23, 2018 Thanks for the info, sounds like engine change would be easier Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.