I've setup a system (for a map I help with) that has 3 capture points, which is why I was able to help here. I use an array of size 3 for each of these points and the variable type is a record that contains a handful of dialog / dialog items and variables. I prefer to create dialogs at map start and just show/hide them instead of dynamically creating them, but I suppose it all depends on the need.
For a lot of capture points, off the top of my head, I would say just do what I am doing and increase the array size. It would be possible to do all this for virtually any number of capture points, even if they changed locations and/or quantity on a game-by-game basis. Thank you for your picture, BTW, aZergBaneling. I was too lazy X_X
Starting Cap: Here's how I would do this. Create 1 global boolean variable for each building that can be "capped". This variable will be false if no units are capping the building and true if they are. The trigger that fires when a player enters the building's region will have a condition that the boolean variable associated with this building be false.
Capping Timer: I don't use the built-in timer functions. My recommendation is to use a real variable and call it something like "timer". Set the real variable to the time required to cap. Use a while loop with the condition that the timer be greater than 0 and, in the loop wait, then decrease the timer variable by however long you waited. That's just the timer part. Someone wrote a great guide to using waits, check it out here: "Waits in SC2 - oddities and solutions"
Now you'll need to check to make sure that the player that started capping the building is still in the region. That's easy enough - just use the "Unit In Region" function to check that the player is still in the region. What if the player leaves the building region? Now you need some way to tell the while loop that it should stop because the building was not capped. Use another boolean variable (private). Set it to false if the player leaves the region and, in the condition for your while loop, add a condition that this boolean variable be true. So the condition will be that timer is greater than 0 and boolean variable ("continueCap" ??) be true.
You still need to check if an enemy player has interrupted the cap. You can make use of the same boolean variable to tell the while loop to stop the timer. To check to see if an enemy player has interrupted the cap, use a private unit group variable. After you check to make sure the capping player is still in the region, set the unit group variable to units in region with alliance to player. You can make this as simple or complicated as you want, but the simplest way would be to set the unit group to look for units in the cap region with enemy alliance to the capping player with max amount 1. If the size of the unit group variable, the number of units it found, is more than 0, stop the timer because someone interrupted the cap.
In reply to aZergBaneling:
In reply to Reason:
Now you'll need to check to make sure that the player that started capping the building is still in the region. That's easy enough - just use the "Unit In Region" function to check that the player is still in the region. What if the player leaves the building region? Now you need some way to tell the while loop that it should stop because the building was not capped. Use another boolean variable (private). Set it to false if the player leaves the region and, in the condition for your while loop, add a condition that this boolean variable be true. So the condition will be that timer is greater than 0 and boolean variable ("continueCap" ??) be true.
You still need to check if an enemy player has interrupted the cap. You can make use of the same boolean variable to tell the while loop to stop the timer. To check to see if an enemy player has interrupted the cap, use a private unit group variable. After you check to make sure the capping player is still in the region, set the unit group variable to units in region with alliance to player. You can make this as simple or complicated as you want, but the simplest way would be to set the unit group to look for units in the cap region with enemy alliance to the capping player with max amount 1. If the size of the unit group variable, the number of units it found, is more than 0, stop the timer because someone interrupted the cap.