Ejemplo n.º 1
0
void renderscores() {
	if (!scoreson)
		return;
	scorelines.resize(0);
	if (!demoplayback)
		renderscore(player1);
	for (int i = 0; i < players.size(); ++i) {
		if (players[i])
			renderscore(players[i]);
	}
	sortmenu(0, scorelines.size());
	if (m_teammode) {
		teamsused = 0;
		for (int i = 0; i < players.size(); ++i) {
			addteamscore(players[i]);
		}
		if (!demoplayback)
			addteamscore(player1);
		teamscores[0] = 0;
		for(int i = 0; i < teamsused; ++i)
		{
			IString sc;
			std::sprintf(sc, "[ %s: %d ]", teamname[i], teamscore[i]);
			strcat_s(teamscores, sc);
		};
		menumanual(0, scorelines.size(), "");
		menumanual(0, scorelines.size() + 1, teamscores);
	};
}
Ejemplo n.º 2
0
void renderscores()
{
    if(!scoreson) return;
    scorelines.setsize(0);
    if(!demoplayback) renderscore(player1);
    loopv(players) if(players[i]) renderscore(players[i]);
    
    // Added by Rick: Render Score for bots
    loopv(bots) if(bots[i]) renderscore(bots[i]);
    
    sortmenu(0, scorelines.length());
    if(m_teammode)
    {
        teamsused = 0;
        loopv(players) addteamscore(players[i]);
	
	// Added by Rick: Add team scores for bots
	loopv(bots) addteamscore(bots[i]);
	
        if(!demoplayback) addteamscore(player1);
        teamscores[0] = 0;
        loopj(teamsused)
        {
            sprintf_sd(sc)("[ %s: %d ]", teamname[j], teamscore[j]);
            strcat_s(teamscores, sc);
        };
        menumanual(0, scorelines.length(), "");
        menumanual(0, scorelines.length()+1, teamscores);
    };
};