A very good point you just made, not just seeing someone else can fuel the urge but getting the news of a big win by someone can also attract someone who has stopped gambling to try again with the shape of being lucky too just like the news he just heard, quitting gambling is not yet easy to avoid going back again the person should avoid getting closer to gamblers nor listening to their success stories.
Indeed, our environment can also influence us. For example, if we've reduced our gambling, but we're surrounded by friends who gamble, and someone wins, and we hear about it, this can honestly lead us to gamble again. The mindset might be that if our friend wins, we might win too. This news of winning can build a desire to gamble again.
Quitting gambling is possible, as long as we have a strong determination.