View Single Post
Old 11-28-2013, 10:09 PM   #7
ddm999
worst ff player eu
 
Join Date: Jun 2012
Location: South Yorks., England
Class/Position: o - no, d - scout
Gametype: IvDZ
Posts Rated Helpful 18 Times
I think you should remove this:
-- If either team has no players, then exit. Just one person running about shouldn't get boxed up.
if (blue:Count() == 0) or (red:Count() == 0) or (green:Count() == 0) or (yellow:Count() == 0) then
AddSchedule("respawnall", 1 , respawnall)
end




It skips game winning if any team has 0 players, meaning it'll only work with 4 players (one per team). That code is part of CheckTeamAliveState, so it is run on a kill.


If I'm right, then with 2 players your game isn't actually working, and neither team will be getting points, messages, etc. It will just reset in 1 second (should reset in 3 with points added, a message onscreen and a bloop sound effect).


-- If there aren't 2 players, speed up respawn and disable points for the 1 person / no-one.
if (blue:Count() + red:Count() + green:Count() + yellow:Count() < 2) then
AddSchedule("respawnall", 1 , respawnall)
end



If everything I've said before works, plonk this in where the old code was. Bear in mind that if there are 2+ players, but they are on the same team, it will causes the team to receive points if one suicides. I may be able to make some code tomorrow that only allows teams with the least players to be picked to be joined.


Hope this works for you.
__________________
gg ff not ded
ff very much alive
ddm999 is offline   Reply With Quote