fix for crosshair not showing when spectating;

fix for setfollowplayer 0 crashing the game in bot mode

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@7251 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
Cristian Vlasceanu
2013-02-22 20:30:26 +00:00
parent 351f4a96dc
commit 491fb73c2d
2 changed files with 3 additions and 2 deletions
+1 -1
View File
@@ -1669,7 +1669,7 @@ void spectate()
void setfollowplayer(int cn)
{
// silently ignores invalid player-cn value passed
if(players.inrange(cn))
if(players.inrange(cn) && players[cn])
{
if(!(m_teammode && !watchingdemo && team_base(players[cn]->team) != team_base(player1->team)))
{