// initialize jwplayer var playerInstance = jwplayer('player');// player dom elements var playerContainerEl = document.querySelector('.player-container');// returns video player position from top of document function getElementOffsetTop(el) { var boundingClientRect = el.getBoundingClientRect(); var bodyEl = document.body; var docEl = document.documentElement; var scrollTop = window.pageYOffset || docEl.scrollTop || bodyEl.scrollTop; var clientTop = docEl.clientTop || bodyEl.clientTop || 0; return Math.round(boundingClientRect.top + scrollTop - clientTop); }// returns the current y scroll position function getScrollTop() { var docEl = document.documentElement; return (window.pageYOffset || docEl.scrollTop) - (docEl.clientTop || 0); }// configure jwplayer instance playerInstance.setup({ autostart: true, playlist: 'https://cdn.jwplayer.com/v2/playlists/mYdavspX', primary: 'html5', setFullscreen: true, width: '100%' });// when jwplayer instance is ready playerInstance.on('ready', function() { var config = playerInstance.getConfig(); var utils = playerInstance.utils; // get height of player element var playerHeight = config.containerHeight; // flag determining whether close has been clicked var closed = true; // CHANGED // flag determing whether player is playing var playing = false; // ADDED // eventhandler for when close button is being pressed document.getElementsByClassName('icon-close')[0].addEventListener('click', () => { closed = true; onScrollViewHandler(); }); playerInstance.on('play', function() { closed = false; playing = true; // ADDED }).on('pause', function () { playing = false; // ADDED }).on('adPlay', function() { closed = false; // ADDED playing = true; // ADDED }).on('adPause', function() { playing = false; // ADDED });// get player element position from top of document var playerOffsetTop = getElementOffsetTop(playerContainerEl);// set player container to match height of actual video element playerContainerEl.style.height = playerHeight + 'px';// below we handle window scroll event without killing performance function onScrollViewHandler() { var minimized = getScrollTop() >= playerOffsetTop;if (closed && minimized) { minimized = false; jwplayer().pause(); playing = false; // ADDED } else if (!minimized && !playing) { closed = true; // ADDED } utils.toggleClass(playerContainerEl, 'player-minimize', minimized); // update the player's size so the controls are adjusted playerInstance.resize(); }// namespace for whether or not we are waiting for setTimeout() to finish var isScrollTimeout = false;// window onscroll event handler window.onscroll = function() { // skip if we're waiting on a scroll update timeout to finish if (isScrollTimeout) return; // flag that a new timeout will begin isScrollTimeout = true; // otherwise, call scroll event view handler onScrollViewHandler(); // set new timeout setTimeout(function() { // reset timeout flag to false (no longer waiting) isScrollTimeout = false; }, 80); };});

Announced a few weeks back by SCUF Gaming and Activision, the new SCUF Vantage 2 Call of Duty: Modern Warfare Limited Edition Controller for PlayStation 4 and PC is now available ahead of the game’s launch on October 25.

The SCUF Vantage 2 Call of Duty: Modern Warfare Edition is available for PlayStation 4 and PC and can be purchased now starting at $219.95 on SCUF Gaming’s website or at GameStop retail stores.

The design of the Modern Warfare Controller sees an exclusive topographic map faceplate, the Modern Warfare logo on the Touch Pad, and other Modern Warfare inspired details across the product. This product is officially licensed controller from PlayStation and Activision.

“Nine years ago, we invented the SCUF to enable gamers to improve their gameplay on fast-paced shooter games like Call of Duty, so this is a community we are both passionate and very engaged with,” said Ironmonger. “We’ve equipped countless players with the high-performance controllers they need to win. Whether playing at home, in a professional tournament, or elsewhere, SCUF has become the de-facto controller in the competitive community. This limited-edition controller marks another exciting chapter for both Scuf Gaming and the Call of Duty franchise.”

SCUF also announced that people who buy this new controller will receive a bonus in-game digital item, a sniper scope weapon charm, in Call of Duty: Modern Warfare to use in-game.

Activision has partnered with many brands this year to bring Modern Warfare themed content and gear for the game’s launch, including partnerships with Mountain Dew and Doritos and Totino’s to have 2XP codes and in-game bonus items with purchases of the different products for this year’s release. 

comments below