1. If you want 1 group to board 1 truck you don't need any code. Just use the waypoints, that's what they are for.
You know the code to make a group board a specific truck, you quoted it in your question. The only question is where to put it. Waypoint, trigger or script it doesn't matter, as long as you make the code execute at the right time.
Code in a waypoint does not have to relate to the group to whom the waypoint belongs.
2b. Create an array of all you soldiers. Whenever you want to check that everybody is aboard use a vehicle command something like this
? vehicle loon1 == loon1 : he is still walking so whatever consequence you want