Jump to content

Custom logic of movement in the render method


nepalez
 Share

Recommended Posts

Hi all, I have some troubles with Pixi render behavior. Now I have a container that renders a list of sprites, like this:

 protected _render(renderer: PIXI.Renderer): void {
    for (let i = this.items.length - 1; i >= 0; i--) {
    	let item = this.items[i];    	
    	item.render(renderer);
    }
}

All of them are located at the start position, (0, 0). The position was calculated from inside a game loop. Actually need to do something with transformation when my render works, but I don't know what.

Link to comment
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...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...