TRCMarker
First and foremost this is (again) a proof of concept little program for low level .trc
file generation and baking the resulting native road game objects into the loaded map-rpk.
The viewport can be navigated with the mouse:
-Holding down the middle button and dragging will pan the camera.
-Holding down the left button and dragging will rotate the camera.
-Holding down the left ctrl button on the keyboard and panning
will move the camera slower.
-Holding down left shift will move the camera up/down
Moving the camera also moves the "Marker"
(little circle in the centre of the viewport)
The marker selects the current trc-object.
-There are 4 types of trc-objects:
-Lane:
The intersections are connected by lanes these are made up of
cubic bezier curves a curve will be referd to as an SplSegment
-Each segment has a Source point and a Target point and two intermediate points
which will define the derivatives of the curve.
-RedIntersection:
-GreenIntersection:
-The interesections are made up of "Crossing lane"-s each Crossing lane is
one SplSegment the GreenIntersections are regulated by an internal traffic
light the red ones are regular intersections.
-NavigatorLane:
-Syntactically same as a lane but does not connect intersections and is
mainly an internal part these nodes are automatically generated on saving
and can not be edited.
Buttons on the UI:
-Render: Opens a file dialog and will load the POLY data from the selected RPK,
this RPK will be the target for the generated game objects.
-AddRender: Opens a file dialog and adds the POLY data from the selected RPK.
-AddTRC: Opens a file dialog and adds the trc-objects of the selected .trc file.
-Del: Delets the current trc-objects (all of them)
-SaveONLYTrc:~
-SaveTrc: Will save the .trc file and will bake the generated
native road objects into the selected rpk.
-BakeTrcToRpk: Will not save the .trc file, ~.
-NewSection1: Will add a new RedIntersection at the marker with one Crossing lane.
-NewSection2: Will add a new GreenIntersection at the marker with one Crossing lane.
-NewLane:~
-DupLane: Will duplicate the currently highlighted lane.
-DelSelected: Will delete the currently highlighted trc-object.
-ShowSpatial: Will show the spatial strcuture of the rpk related to the current position.
-HideSpatial:~
-LockSelection: Locks the currently selected trc-object
(no new trc-object can be selected with the marker, it can move freely)
IF THE SELECTED TRC-OBJECT IS A INTERSECTION:
-ClearSelection: Clears any selection made (even the selected Crossing lane)
-AddCrossing: Adds a new Crossing lane at the marker (to the selected Intersection)
-DeleteCrossing: Removes the Crossing lane selected in the listbow below.
-Switch Type (..): Switches between green and red intersection types.
-LanePriority: If higher the lane will be "open"/"green" for longer.
-LaneType(MUST SET): will define the semantic of the crossing lane.
IF THE SELECTED TRC-OBJECT IS A LANE:
-Adjacent lanes: the two comboboxes can be used to select the logically adjacent lanes
(meaning the traffic cars can switch to these by lane switching)
(look for the blue-highlighted lanes in the viewport)
-GenerateAdjacentLanes: Will try to figure out which would be the most probable adjacent lanes.
-MaxSpeed: Max legal speed of the lane.
-End float 2: Related to the priority of the lane for traffic car generation.
-ClearSelection: Clears any selection made (even the selected SplSegment)
-PointToStart: Add a new SplSegment to the Source of the lane.
-PointToEnd: Add a new SplSegment to the Target of the lane.
-DelSegment: Delete the SplSegment selected in the listbox below.
-Reverse: Will reverse the lane.
Buttons for SplSegment editing:
-SnapToClosest: SNAPPING IS IMPORTANT! this will snap the current selected endpoint
(source or target) to the closest other endpoint forming a logical connection as
well to connect a lane to a Crossing lane they must be snapped together.
-RecalcSnapping: Will recalculate the snapping from relative positions of the endpoints.
-BreakSnapping: Will invalidate the current snapping of the selected SplSegment.
-MoveSrc: The marker will move the Source of the current SplSegment.
-MoveTarget:~
-MoveSrcNormal:~
-MoveTargetNormal:~
Download from GoogleDrive
If you have feedback please use this forum : LINK