// 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); };});

Activision has just announced “Call of Duty Championship” which will take place in Hollywood this April. There will be 32 teams from around the world that will compete for a share of $1 Million in the first annual Call of Duty Championship, presented by Xbox. Tune in to the worldwide broadcast April 5-7 to see who comes out on top.

20130201-094555.jpg

Full Press Release:

Santa Monica, CA – February 1, 2013 – It’s time for gamers the world over to mark their calendars, because the ultimate high-stakes Call of Duty competition is coming this April, forever changing the face of competitive eSports. The Call of Duty Championship, presented by Xbox, featuring a $1 million Call of Duty®: Black Ops II tournament, will take place in Hollywood, CA April 5-7. Activision Publishing, Inc., a wholly owned subsidiary of Activision Blizzard (Nasdaq: ATVI) and their award-winning studio Treyarch, in partnership with Xbox®, Major League Gaming (MLG) and the Electronic Sports League (ESL) will bring together 32 of the world’s most skilled multiplayer teams on the Xbox 360® video game and entertainment system from Microsoft to compete head-to-head in Call of Duty: Black Ops II in a live-streamed spectacular to be broadcast to the masses.

“More people play Call of Duty multiplayer every day than watch the average regular season game of the NBA. The scale and passion of the Call of Duty fan base is simply humbling, and yet there is no formal way to find out who amongst those millions of players is the best of the best, until now,” said Eric Hirshberg, CEO of Activision Publishing. “Watching the performances of the very best Call of Duty players is already a mass spectator sport on YouTube and Call of Duty® Elite. We are going to bring the best players in the world to Hollywood to compete on the ultimate stage, for the ultimate prize. And we are going to invite our entire worldwide fan base to join in the fun.”

Beginning today, players interested in participating in the tournament can go to https://elite.callofduty.com/esports and register for a free Call of Duty Elite account – it takes just a few seconds. Once registered, teams of four can vie for entry into the Call of Duty Championship, presented by Xbox tournament by competing in the February season of League Play in Call of Duty: Black Ops II on Xbox LIVE®, which opens today. Following the close of the February season, the top eight eligible teams will earn coveted spots in the Call of Duty Championship, presented by Xbox, including a trip to Hollywood this April to compete for the $1 million tournament purse.

“It’s an absolute honor to have players and fans celebrate the thrill of competition on such a grand stage,” said Mark Lamia, Treyarch studio head. “From the very beginning of development for Call of Duty: Black Ops II, we committed to making eSports an integral part of the game, and it’s going to be awesome to watch the best teams in the world battle it out for everyone to see.”

Additionally, teams competing in the recently announced MLG 2013 Pro Circuit featuring Call of Duty: Black Ops II (www.majorleaguegaming.com) will vie for a chance to enter the Call of Duty Championship, presented by Xbox. At the MLG Winter Championship, March 15-17, in Dallas, Texas, the top eight teams will earn trips to Hollywood to play against the best Call of Duty players in the world. Joining them will be eight winning teams from the ESL’s European Finals (http://cod.esl.eu) taking place March 16-17, in the famous ESL Arena live eSports Studios in Cologne, Germany.

comments below