Sentinel

Pixi.js renderer not working

Recommended Posts

So basically I have a big project ongoing.
Instead of having nested constructors that passed down all the game data such as renderer, resources and so on, I decided in my Game.js file to make it static and then require that in every other file and directly get the required data through there.

It is quite a big project, so I am not going to include files, instead I'll be linking to my git repository.

The issue is that nothing gets rendered on the screen and no errors are shown at all. I've tried 2 different browsers aswell.

I've tried with both the CanvasRenderer and WebGLRenderer yet the same error still occurs.

 

And I've checked the PIXI Container that gets rendered, and it does contain children of other DisplayObjects.

 

https://github.com/marcus-sa/StormEngine/tree/dev/client

4urNnHZ.png

Share this post


Link to post
Share on other sites
4 minutes ago, ivan.popelyshev said:

Code looks fine. Can you give me a webpage to debug? I have a list of things to check in my mind.

Uhh I'll see what I can do here, because it's implemented into a CMS I've written, so I would first have to set it up on Heroku and get a remote control MySQL server then.

Share this post


Link to post
Share on other sites
2 minutes ago, ivan.popelyshev said:

I'm asking that because code really looks fine. By the way, for camera and other things, I recommend to look at "pivot+position" combo , I mentioned it too many times in this subforum.

Yeah I've seen you mentioning it a couple of times, but for now in this prototype the camera does its purpose.

I'll reply back to the thread when I can give you a webpage to debug.

Share this post


Link to post
Share on other sites
1 hour ago, ivan.popelyshev said:

I'll use discord later, im not ready right now :) may be in 2 hours.

I fixed it.
Had something to do with the height and width of the renderer.

options.container.offsetWidth
options.container.offsetHeight

and

this.config.container.offsetWidth
this.config.container.offsetHeight

was what made the renderer not show anything at all, so I switched them out with what I had before which was

window.innerWidth
window.innerHeight

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...

  • Recently Browsing   0 members

    No registered users viewing this page.