Skip to content

adding a Skybox #7

Description

@rontrek

Hi, I see that the forum is now read only and noted to post here on GitHub for questions, so in particular I'm trying to create a background skybox for a twopointfive level. I did search for previous related post here:

https://impactjs.com/forums/impact-engine/impact-1-24-pseudo-3d-web-audio

but with no luck and somehow can't get it to work. What I have done so far is cleared a part of the ceiling assuming it will be drawn there.

main.js

init: function() {
...
this.skyboxImage = new ig.Image( 'media/skybox.png' );
this.skyboxImage.width = screen.width;
this.skyboxImage.height = screen.height;
this.skyboxQuad = new tpf.HudTile( this.skyboxImage, 0, screen.width, screen.height);
this.skyboxQuad.setPosition(0, 0, 0);		

...
...
...

drawWorld: function() {
this.skyboxQuad.draw();
this.parent();
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions