怎样创建类似这样的对象呢? {roomName1: {player1: clientIdOfPlayer1, player2: clientIdOfPlayer2}, roomname2: { player1: clientIdOfPlayer3, player2: clientIdOfPlayer4} 其中roomName、clientIdOfPlayer1、clientIdOfPlayer2都是变量。 求大神指点
作者
怎样创建类似这样的对象呢? {roomName1: {player1: clientIdOfPlayer1, player2: clientIdOfPlayer2}, roomname2: { player1: clientIdOfPlayer3, player2: clientIdOfPlayer4} 其中roomName、clientIdOfPlayer1、clientIdOfPlayer2都是变量。 求大神指点