facebook-instant-games

Facebook Instant Game - Uploading bundled zip file gives SDK reference error from Web Hosting

风格不统一 提交于 2020-06-17 09:13:28
问题 When I try to upload my simple game/app, I get an error saying "Games must reference one of our supported SDKs via our CDN." I have given an SDK reference though. Isn't this the one? <script src="https://connect.facebook.net/en_US/fbInstant.6.2.js"></script> I went through the SDK reference of facebook docs as well but it didn't work for me? Did anyone face same situation before or have an idea to fix this problem? thank you I have a file index.html INDEX.HTML <html> <head> <title> this is

Facebook Instant Game - Uploading bundled zip file gives SDK reference error from Web Hosting

北城以北 提交于 2020-06-17 09:12:01
问题 When I try to upload my simple game/app, I get an error saying "Games must reference one of our supported SDKs via our CDN." I have given an SDK reference though. Isn't this the one? <script src="https://connect.facebook.net/en_US/fbInstant.6.2.js"></script> I went through the SDK reference of facebook docs as well but it didn't work for me? Did anyone face same situation before or have an idea to fix this problem? thank you I have a file index.html INDEX.HTML <html> <head> <title> this is

(FB Instant games) How I can get/set screen resolution?

自作多情 提交于 2020-01-04 07:54:18
问题 How can I get/set screen resolution for instant games in mobile facebook app or mesenger? I tried getting that by "window.screen.width" and "window.innerWidth", it returned me 360 pixels (but i have 980 in Chrome browser). I haven’t used any meta tags which can limit the resolution. 回答1: You need to use window.innerWidth and window.innerHeight . You need to multiply these by window.devicePixelRatio . So: PixelW = window.innerWidth * window.devicePixelRatio; PixelH = window.innerHeight *

Facebook bot not receiving messaging_game_plays webhook events even though webhook is subscribed to those events

筅森魡賤 提交于 2019-12-25 01:36:38
问题 I'm testing a facebook instant games app and want my bot to collect messaging_game_plays events to log user data at the end of a play session. I've set up an app page, app, and uploaded a build that I have moved to the testing stage. I also have a bot with a public webhook that I have successfully verified. The webhook is currently subscribed to messaging_game_plays as well as messages . I have simple echo functionality built into the bot and can spin up the messenger app on my phone, message

Instant Games Content Security Policy

随声附和 提交于 2019-12-11 14:59:27
问题 Does anyone know if there's a way around this security policy for Facebook Instant Games? I'm trying to load a video using a local blob that I'm downloading using Fetch(). Content Security Policy: The page’s settings blocked the loading of a resource at blob:https://XYZ (“default-src https://XYZ”) Using the video's direct URL as the video.src isn't an option for me. Any thoughts? 回答1: I work on the Instant Games team. The preferred approach is to store any assets for your Instant Game in the

Facebook Instant game bot message often results in “Cannot send Instant Game message to user at this time”

佐手、 提交于 2019-12-11 05:10:02
问题 I'm making a Facebook instant game, and am sending myself test messages via the associated bot. It works. But not always, why? Very often I get this: { "error": { "message": "(#100) Cannot send Instant Game message to user at this time.", "type": "OAuthException", "code": 100, "error_subcode": 2018144, "fbtrace_id": "DNZhKZlP83D" } } This error code is not listed in the error code documentation. I suppose it could be some message sending limit, but I would assume that as the listed developer

How to create a Phaser button in Facebook instant games for a mobile device

蓝咒 提交于 2019-12-02 07:27:29
问题 I am trying to create a button with Phaser 2 CE on a mobile device but it doesn't fires, even if it works fine on desktop, the entiere code will be on my github repository but for the moment i can just display an image like in the code bellow var game = new Phaser.Game(640, 480, Phaser.AUTO, 'game', { preload: preload, create: create, update: update }); function preload () { game.load.image('logo', 'assets/phaser2.png'); game.load.image("upArrow", "assets/up.png"); } function create () { //

How to create a Phaser button in Facebook instant games for a mobile device

时光总嘲笑我的痴心妄想 提交于 2019-12-02 03:17:44
I am trying to create a button with Phaser 2 CE on a mobile device but it doesn't fires, even if it works fine on desktop, the entiere code will be on my github repository but for the moment i can just display an image like in the code bellow var game = new Phaser.Game(640, 480, Phaser.AUTO, 'game', { preload: preload, create: create, update: update }); function preload () { game.load.image('logo', 'assets/phaser2.png'); game.load.image("upArrow", "assets/up.png"); } function create () { // Initialize player //player = game.add.sprite(20, 20, 'logo'); game.device.desktop || addMobileInputs();