Hi, I’ve been playing around with your plugin for a few weeks and I have to say it’s awesome! I followed guide to get my first tank up and running using the M113 model. I used your movement, tracks and suspension and inherited all that behavior from MMPawn into my own tank base class that contained some basic AI & Turret/Barrel movement etc. This worked really well, my classes were able to run on top of your MMPawn class without any issues besides a few variable renaming.
I am now trying to make an Abrams tank but use the T26 base instead of the M113. I think I’m really close to having it hooked (I think) but there’s no guide so I’ve been trying and failing until something works. There’s some weird behavior that I am not sure what it could be. I am going to outline my process I used so far first and then present the weird behavior. It’s likely something super simple, but I’ve been looking and I can’t seem to see it.
So I chose to use the ModularDriveTrainV2 to base the Abrams tank off of. Reason for this was because the suspension implemented in the example was “somewhat” close to what I would need (it didn’t have the little suspension pieces that the T26 normally does at the bottom) and I thought that removing the modular drive and replacing it with the arcade movement would be easier than the other way around if I had chosen to base it off LightTankPureBP. I’m not sure if this was the right call.
This is what I ended up with after removing the modular drive, adding wheels ( to make them fit I just scaled the entire wheel hierarchy to 2.1/2.1/2.1, not sure if this is wrong vs using the linear limit or something (linear limit is set to 15 right now)) and adding all the necessary array elements to update TrackAnimationDriveR / TrackAnimationDriveL.
Front view after adding the physics wheels and updating splines:
TrackAnimationDriveR/L:
RoadWheelPhys01R (Static Mesh Component):
RoadWheelTAF01R ( Track Anisotropic Friction):
RoadWheelPhys01PCR ( Physics Constraint Component):
UpdateFriction / ResetFriction functions updated:
To update the functions above and the Event Graph below I copied the way LightTankPureBP was implemented.
Event Graph:
The movement/input portion of the top of the event graph looks just like LightTankPureBP, I did not want to add 4 more pictures just to cover this as it’s identical.
I also added six (one for each new wheel ) of the OnComponentHit nodes:
I think those are all the adjustments I made so far (I think, it’s hard to remember back to all the minor changes I made along the way but those should be the main ones) and in view port this is what the tracks look like:
PROBLEM:
However, when I press play and possess the vehicle the wheels and track act really strange and I’m having a difficult time figuring out where I screwed up. Basically, the wheels are jittery, they do not line up correctly and the track goes all crazy. The tank moves ever so slightly if I hold down the throttle but for the most part the wheels just spin and the tank stays in place. I feel like there’s a fundamental lack of understanding of the principles behind the physics involved here that I’m not getting so I am not able to configure it right. This is what it looks like, the spockets and wheels spin, the track moves as well but as you can see not exactly correctly:
Any help is appreciated! It would be nice it this could turn this into a short “how to guide” to better understand how to utilize your new implementations with various different chassis types and wheel configurations. Again, this is an amazing plugin and I just want to thank you again for your contribution, cheers.