Quantcast
Channel: JavaScript and TypeScript — Photon Engine
Browsing all 162 articles
Browse latest View live

Photon Cloud Poll in/out for sending message in the room ( lost packet)

Hello, I am using Photon Cloud for the matchmaking system and using a custom message with event code (number 1). most of the time it worked well but sometimes when four players send a message to set...

View Article


Javascript Switch or Set Master Client

Hello! Photon Unity has the method: PhotonNetwork.SetMasterClient(photonPlayer); What's the Javascript equivalent for this? I can't seem to find it. Thanks!

View Article


Prevent clients from creating rooms

Hello - I am wondering if there is a way to setup my app such that anonymous clients, which access photon using a website and the js sdk, can join rooms, but not create new rooms, and only the "server"...

View Article

Image may be NSFW.
Clik here to view.

How connect Photon SDK js

I can't connect photon SDK, used this method but got the error "Failed compiled" TypeScript error in /Projects/dots_and_boxes/src/libs/Photon-Javascript_SDK.d.ts(9,1): Definitions of the following...

View Article

Construct 3 uncaught error

So, I just tried to open the demo-pool file from you guys, and I get this error on the console: Uncaught TypeError: Cannot read property 'Photon' of undefined at b497a020-dc67-40ab-a228-4b2815ace75c:4...

View Article


Server Timestamp?

Photon Unity allows you to get the timestamp of a message with PhotonMessageInfo and SentServerTimestamp. Getting a timestamp is pretty critical item, I don't see this functionality in the JS engine....

View Article

4-1-1-0 Updates

Hey! Just noticed a few small things in the 4-1-1-0 changes I figured I'd mention. In Photon-Javascript_SDK.js, line 1894 added a comment: `@property {string} [options.region] If specified, Connect ro...

View Article

How to connect to On-Premises server?

I am trying to connect a Discord bot to a Photon On-Premises server, however the documentation doesn't really explain how to do that. From the looks of it, I can only connect to a Photon Cloud...

View Article


PhotonPeer Not Defined

When I am creating a PhotonPeer to connect to my server, it always show the error UnhandledPromiseRejectionWarning: ReferenceError: PhotonPeer is not defined . I am at a lost and not sure what to do.

View Article


Frequent Disconnections (MasterTimeout- 1004 , GameTimeout - 2004)

Hello folks, I have been using photon for quite some time now, mostly used PUN2 in unity and never had any issues regarding frequent disconnections. I have a turn based game (made in cocos creator) in...

View Article

Javascript SDK not able to connect to rooms created in PUN2 client

I have a Unity client that creates the room. But when I try to connect to the same room I get the following error:Operation 226 error: Game does not exist (32758) I am using the same region, the same...

View Article

When do avatars destroy?

Do avatars which instantiate via Photon also get destroyed (or hidden or some other 'remove from view') automatically? Or should I look for 'OnPlayerLeftRoom' and destroy their avatar?

View Article

ChatClient Subscribe createOption

Hi, I'm new to the photon. I would like to know why I got an error when I try to enable the createOption in subscribe ChatClient?WS message: { type: 'utf8', utf8Data:...

View Article


Any way to compress a cached file?

have a successfully working page where a visitor can record a video via html5 < video > via web cam. Once it's recorded it automatically Plays the just recorded video (and then can be uploaded)....

View Article

Image may be NSFW.
Clik here to view.

Construct 3 Runtime Issue

The newest version of the Construct3 Photon plugin does not seem to be working at all. This was using the example file in the SDK. I have set to wss with No workers, yet only get a black screen. I...

View Article


Image may be NSFW.
Clik here to view.

Webhook for Construct3 is not working?

Hi,I have downloaded Construct3 sdk v4.1.1.0 and try to run demo-pool.c3p.If I added webhook callback, then I got the error "Room is setup with unexpected plugin. Please help me to resolve this...

View Article

Construct 3 demo-chat

The chat demo for Construct is not working. Keeps throwing the following error:ERROR:Client: Master: PhotonPeer[_onMessageReceived] - Received undefined message type: {"err":-37,"msg":"OpCode_5 is...

View Article


Image may be NSFW.
Clik here to view.

Uncaught TypeError and Unreliable events (Construct 3)

I have a turn-based game made in Construct 3 + Photon.Often when receiving events, this message appears on the console. But most of the time the game seems to work fine. What does that mean? Same...

View Article

Image may be NSFW.
Clik here to view.

Playcanvas Photon connection error

hello, i use photon inside playcanvas game engine.and maybe 1 time of 3 i have this error.can't get any good info about it.do you know what can it be about?thank you

View Article

Two Players at same time create two rooms, JoinRandomOrCreateRoom not found...

Hi,I'm using (Real-time) Photon-Javascript_SDK.js (libversion=4.1.0.0) for COnstruct 2. Sometimes, when two players try to join a game, it could happen that each will create its own room (instead of...

View Article
Browsing all 162 articles
Browse latest View live