RoadRiver API

editor.createRoad(roadInfo)
  • nodes - list of nodes to create the road with, fields per node:

    • pos - position of the node
    • width - width of the node
  • roadInfo - dictionary with the fields that should be set for the new road

Return road object id

Create a new road object.

editor.deleteRoad(roadObjectId)
  • roadObjectId - the road object id

Delete the road object specified by its id.

editor.addRoadNode(roadObjectId, nodeInfo)
  • roadObjectId - the road object id
  • nodeInfo - the node info table, fields:
    • position - node position
    • width - node width
    • index - node index to insert node into. Use U32_MAX to insert at the end.

Return new node id

Add a new road node to a road object.

editor.deleteRoadNode(roadObjectId, nodeId)
  • roadObjectId - the road object id
  • nodeId - the node id

Delete a road node by its id.

editor.createRiver(riverInfo)
  • riverInfo - river descriptor table, fields:
    • wip - wip

Return river object id

Create a new river object.

editor.deleteRiver(riverObjectId)
  • riverObjectId - the river object id

Delete a river object by its id.

editor.addRiverNode(riverObjectId, nodeInfo)
  • riverObjectId - the river object id
  • nodeInfo - the node info table, fields:
    • wip - wip

Return the new river node id

Add a new river node.

editor.deleteRiverNode(riverObjectId, nodeId)
  • riverObjectId - the river object id
  • nodeId - the node id

Delete a river object node by its id.

editor.createRoadMesh(roadMeshInfo)
  • roadMeshInfo - the road mesh info table, fields:
    • wip - wip

Return the road mesh object id

Create a new road mesh object.

editor.deleteRoadMesh(roadMeshObjectId)
  • roadMeshObjectId - the road mesh object id

Delete a road mesh object by its id.

editor.addRoadMeshNode(roadMeshObjectId, nodeInfo)
  • roadMeshObjectId - the road mesh object id
  • nodeInfo - the node info table, fields:
    • wip - wip

Return the road mesh node id

Add a new road mesh node.

editor.deleteRoadMeshNode(roadMeshObjectId, nodeId)
  • roadMeshObjectId - the road mesh object id
  • nodeId - the node id

Delete the road mesh node by its id.

Last modified: 7 December 2021, at 14:30

Any further questions?

Join our discord