If you were simulating the universe, you wouldn't need to "program in" increasing entropy. It would just happen.
For example, let's say I want to stimulate the mixing of two gases by having a bunch of blue and red particles in a container separated by color by a partition. Let's say I remove the partition, and the only rules in my simulation are that particles move at a constant velocity unless they hit another particle or the container wall, in which case an elastic collision occurs. This is a pretty good simulation of what is going on.
Now, just using this, and not programming in an explicit "entropy increase module", we will see the gasses mix and entropy increase until everything is fully mixed.
The same thing is true for your example. We can stimulatesimulate planets forming, but we don't need to consider entropy to do it. The particles will follow Newton's laws, and then if we wanted to consider what the entropy is doing by looking at the heat/radiation that is produced, we would see that entropy increases.
In other words, the second law always holds, but it is not the cause of anything. It is essentially just saying "the most likely thing that can happen will happen". It's not a driving force of nature, but rather a result of it.