Extending Q-Learning to General Adaptive Multi-Agent Systems