diff options
| author | oy <Tom_Adams@web.de> | 2011-02-10 12:05:55 +0100 |
|---|---|---|
| committer | oy <Tom_Adams@web.de> | 2011-02-10 12:05:55 +0100 |
| commit | 3f05289328dfaeb67a344de0b553e31cbb11ea36 (patch) | |
| tree | 3d41ec1d9a54c5f3a7add26d4be8ebe4572586cd /src/game/server/gameworld.cpp | |
| parent | 0698243c6b79a224582c8c37f9951af0672516b3 (diff) | |
| download | zcatch-3f05289328dfaeb67a344de0b553e31cbb11ea36.tar.gz zcatch-3f05289328dfaeb67a344de0b553e31cbb11ea36.zip | |
fixed a possible problem with occupied spawn points and cleaned up spawn code a bit
Diffstat (limited to 'src/game/server/gameworld.cpp')
| -rw-r--r-- | src/game/server/gameworld.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/game/server/gameworld.cpp b/src/game/server/gameworld.cpp index 66da4369..8fffabc8 100644 --- a/src/game/server/gameworld.cpp +++ b/src/game/server/gameworld.cpp @@ -48,7 +48,8 @@ int CGameWorld::FindEntities(vec2 Pos, float Radius, CEntity **ppEnts, int Max, { if(distance(pEnt->m_Pos, Pos) < Radius+pEnt->m_ProximityRadius) { - ppEnts[Num] = pEnt; + if(ppEnts) + ppEnts[Num] = pEnt; Num++; if(Num == Max) break; |