static Player players[32];
Player* Player_constructor() {
Player* player = malloc(sizeof(Player));
// Do some initializations
return player;
}
...
...
...
players[0] = Player_constructor();
问题在于players[0]
typePlayer
和Player_constructor
is type Player*
。
我该如何克服这个问题?使用参考文献会有帮助吗?