Not sure if you managed to get another request to work, but here is my attempt, definitely working - Sqlfiddle to prove it.
set @x=null;
set @y=0;
select sub.user_id as user_id,max(sub.streak) as streak
from
(
select
case when @x is null then @x:=user_id end,
case
when win=1 and @x=user_id then @y:=@y+1
when win=0 and @x=user_id then @y:=0
when win=1 and @x<>user_id then @y:=1
when win=0 and @x<>user_id then @y:=0
end as streak,
@x:=user_id as user_id
from your_table
) as sub
group by sub.user_id
PHP , , :
mysql_query("set @y=0");
$query=mysql_query("select sub.user_id as user_id,max(sub.streak) as streak
from
(
select
case
when win=1 and @x=user_id then @y:=@y+1
when win=0 and @x=user_id then @y:=0
when win=1 and @x<>user_id then @y:=1
when win=0 and @x<>user_id then @y:=0
end as streak,
@x:=user_id as user_id
from your_table
) as sub
group by sub.user_id");
while($row=mysql_fetch_assoc($query)){
print_r($row);}