Group Details Private

administrators

 

Member List

RE: Filter data

Hi @chaimae, can you describe your real-world scenario on why you need filters?

The filters are experimental and currently consume way too much CPU, I wouldn't recommend for production scenario with many clients.

See docs: https://docs.colyseus.io/colyseus/state/schema/#filtering-data-per-client

posted in Questions & Help
RE: Unexpected EncodeSchemaError and hard to find where tis the problem(solved)

HI @Alan-Jin, by the error message it seems like you're trying to add an Array item into the Array of players instead of a Player instance. The error is going to be thrown only at the next patch, that's why wrapping try/catch during assignments/pushes it doesn't catch it.

I suggest inspecting what's being added to the array.

if (item instanceof Player) {
  console.log("good!")
} else {
  console.log("will throw an error during encoding!")
}

Hope this helps, cheers!

posted in Questions & Help
RE: Bad gateway

Hey @chaimae, I'm in contact with the Arena team to check what's going on with your deployment 🤞 will get back to you soon, sorry for the inconvenience

posted in Questions & Help
RE: Bad gateway

Hey @chaimae, what's the server URL you're connecting to? We only found a indie plan with your username/email. Cheers!

posted in Questions & Help
RE: State not updating in nested object

Hi @arturspon,

Do you possibly re-use Schema instances? Depending on how the schema instance is being moved around (or re-used) within the state, the client-side callback may not trigger the way you expected, unfortunately. If you can provide a minimal reproduction example with your scenario it could help us understand the specific issue you're having.

You could potentially use spot.clone() to make sure a new object is created when sharing the instance is necessary

Hope this helps, cheers!

posted in Questions & Help
RE: Colyseus Server Freezes On Error(solved)

Hi Mitch,

I've never seen this issue being reported, could you share more details about the environment you're running in?

E.g. are you using Windows? which Node.js version? How do you spawn the process? If you can provide a way we can reproduce would also be nice. Thanks

posted in Questions & Help
RE: Smooth Interpolated Movement

Hi @MackeyK24, in the past I've made a simple demonstration of using linear interpolation using PixiJS here: https://github.com/endel/colyseus-pixijs-boilerplate/blob/53b490375f2ce065a880ffc1c87ca9fdee40dbf6/src/client/Application.ts#L119-L123

On this approach, the client-side is interpolating every entity's position towards the latest data available from the server at every frame. No action is being taken at the exact time the update came from the server but at every frame.

Hope this helps, let me know if that works for you

posted in Questions & Help
RE: Which files from colyseus examples to upload to Arena?(solved)

Hi @Terradon, welcome 👋

After running npm run build, you can upload the lib/ diretory to Arena and it should work!

Cheers

posted in Questions & Help
RE: patch-package and deployment(sovled)

Hi @eddiwood, welcome!

That is a good question, afaik Arena does not currently support patching node_modules, I'm curious which package you're patching, and why?

Cheers

posted in Questions & Help
RE: Blocked by CORS Policy.(sovled)

If you're using Arena, please use wss://server.colyseus.dev instead of ws://server.colyseus.dev:2567

posted in Questions & Help