Hey I will try and explain my map and problem as best as I can. I'm making a Defense map with 4 teams. Each team has a defense builder and a unit sender (sends units to other teams to defend against). The unit sender ALSO mines minerals for his team to use. Both are going to be building stuff, so how can I make it so they "share" minerals, if one guy builds something, the other guy looses minerals too?
None.
You can look at my example after looking the wiki, though it is more complicated...
http://www.fileshost.com/en/file/76163/ShareResources-rar.html
Some.
http://www.staredit.net/maplantis/index.php?sid=91106c960c;topic=120I think I was the first to ever ask this question, then Antisleep came to the rescue. It works flawlessly, and it's simple to do, since it's only 4 triggers (each one with binary countoffs, so it's actually more. Use a trigger duplicator to make them). You can see my breakdown in that thread.
Pretty much it compares two values, finds the difference, and adds/subtracts the difference from everyone else. Even though you're subtracting all the minerals each trigger run, it's instant, and won't affect spending in the game. The only real problem is that people are idiots, and don't understand the concept of resource sharing and end up spending everyone's money.
"Parliamentary inquiry, Mr. Chairman - do we have to call the Gentleman a gentleman if he's not one?"