Pokémon Diamond and Pearl were the first major Pokémon games to feature online play, and this feature returns once again in the game remakes, Brilliant Diamond and Brilliant Pearl. Online gaming works largely the same way it did over a decade ago; you must visit the Union Room, where you can fight and trade with other players. Here's how to enter the Union Room in Pokémon Brilliant Diamond and Brilliant Pearl.
To enter the Union Room, first go to any Pokémon Center and you should see two flights of stairs. One goes up, the other goes down a floor. The first will take you to the Local Union Room, where you can interact with players around your physical location who have also entered the room. After defeating Roark, the first gym leader, you can descend the stairs to the Global Union Room, where you can play with people from all over the world via the Internet.
After entering one of the Union Rooms, you can press the "Y" button while wandering the game map to enter one of the Union Rooms at any time, regardless of your current location.
Each Union Room also offers ways to filter who you are playing with. If you want to play exclusively with friends, you can set up a linking code to make sure the only people who can join your room are those who know the code. Additionally, you can also create a Union Room exclusively for your party, which is comparable to a guild / clan in other multiplayer games.