13,104 Commits over 2,800 Days - 0.20cph!
Fixed wheel bogie rotation issues, and saved on network data by sending a float for bogie Y rotation instead of a full Vector3
Fixed trains sitting in the wrong place on the tracks if the centre of the train wasn't exactly between the two wheels, but now the bogie angle ends up wrong. Need to think about this some more
Added a new train engine made out of cube primitives and stuff
Fixed train wheels rotating in the wrong direction if the train had bogie rotation enabled and was facing in reverse direction on the track. Flip the tangent if the train if facing backwards.
Prevent "look rotation viewing vector is zero"
Made independent bogie rotation optional and disabled it for WorkCart (the model isn't designed for it).
Base the calculated WorkCart track positions on the pivot points of the front and rear bogies. Wheel bogies now align perfectly on curves.
Small merge from rail_network to wheel_tangents
Fixed Tomaha rear light not lighting up when braking. Removed unused VehicleLights script.
Fixed modular car camper module rear lights being always on, and fixed some modular car taillights not lighting up when braking.
Subtracted
69268 (accidentally deleted bone setup), and brought back the separate SMLights model. Updated VehicleLight settings.
Added support for VehicleLight to have a different renderer material index per renderer - needed for generic snowmobile. Updated all existing VehicleLights to the new serialized fields.
Get snowmobile vehicle light scripts automatically
Removed warning when spawning workcart on track that's generated at runtime
Fixed train track splines not always updating their data when changing them in editor
Server now determines and sends tangent data for the front and rear wheels, allowing the client to rotate the wheel bogies to match the angle of the track. Added to WorkCart. This still has some issues to sort out so committing to a branch for now.
Added a method to TrainTrackSpline to get a tangent from the lookup-table points. Also auto-formatted a few of my train classes to Rust standard formatting.
Ported some train engine code back into BaseTrain for future wheel work
Don't collate train tracks on the client, it's unneeded
Test map collates train tracks
VehicleLight script now support multiple renderers per script. Updated all VehicleLight users. Set up the generic snowmobile's new lights.
Merge GMLights -> Snowmobile
Added support for train track splines to connect to themselves when collating, making one continuous loop
Merge Main -> Rail Network
Input while riding a horse now takes the player's auto-sprint setting into account
Fixed IsMounted actually returning HasDriver for vehicles (i.e. would return false if there was a passenger and no driver). Introduced in
25915.
Merge Main -> General QOL
Re-check UpdateFullFlag after mount points are spawned in. Fixes the following bug:
- Server crashes while player is mounted.
- Server loads save and dismounts the player. UpdateFullFlag is checked due to the dismount, and currently loaded mount points are zero, so the vehicle has zero mounted but nevertheless is "full".
- The mount points are then loaded
- Vehicle is now stuck thinking it's fully occupied
▄▊▌ ▅▍▊▅ ▄▆▌▊▆▊ █▋ ▅▆'▌ ▇▌█▊▆▄ ▅▄▄▍ (▆▋▊▋ ▇▆▌█▋ █▄▉▌▅▌ ▆▊▍▌▊▅▊▇, ▆▊▍ █▇ █▌▄▍▊ ▅▋█▅▍ ▌█▉▇█▌▋▋▍▆▌▍█▅▅ ▇▋ ▉█▇ ▄█▋▉▄▌█ ▅▍▊▇▇ ▄▋▅█▅▌ ▆██▌.
Fixed WorldSpline build compile (remove #if UNITY_EDITOR check)
█▋▋▉▊▄▋ ▉▌▊█▍▊▌▊▆ ▄▍▆▊▄▍▋▄▌▄█▄█▇█ ▍▅▅▌▇ ▆▇ ▉▌▉▇ (▅▍▄▇▌▊▌ ▆▍▍█▇▌▉ ▄▋▊▉▉▋ ▄▉)
Fixed WorkCart height on above-ground tracks, and collision issues with above-ground tracks. Work Cart now drivers properly above ground with collisions enabled
Added an improved TrainIsland scene
Simplify the taxi kick method now that mount points are stored on each module
Merge Main -> rail_network
Merge TrainOnRails -> rail_network
Fixed magnet crane jittery driving feel (due to interpolation setting). Non-movement rotation is still jittery, that's a more ingrained issue.
Magnet Crane turning was still feeling too fast on a live server. Removed the additional steering torque.
Minor magnet crane tweak after further testing
Fixed work cart gravity calculation being backwards (so uphill was faster, downhill slower)
GenerateRailMeshes now generates a TrainTrackSpline script with a spline that the train can follow. WorkCart can now run on the above-ground rails - but not very accurately as the drop to terrain height that the real tracks use is so far ignored.
TrainIsland track testing scene
Unity was automatically recalculating the Magnet Crane inertia tensor as the crane arm moved, causing it to get pretty unstable if the arm was up high. Now manually overriding the intertia tensor with values that essentially treat the arm component as weightless (we already did this with the centre of mass).
Magnet crane braking/steering