Jump to content

kutas

Members
  • Content Count

    5
  • Joined

  • Last visited

  1. i got my camera following sprite by setting pivot to sprite position on every move but the question is how the hell that works? For me its very unintuitive. As far as i know pivot is just only a point that describes position where every transformations occurs but nothing more. Here im not moving my camera position so how why that moves? I've worked with many engines, graphiics softwares and never seen that just changing pivot position caused any transformation.... Steps are: Set stage to the center (which is x 400 y 300) add player to that stage on default position relative to s
  2. and what is best approach to do that? Lets say i have map 8000x8000 i give starting point for x4000, y4000 and create my view container with rectangle slice of the map of coords x3000 and width 2000px / y3000, width 2000px and then every character move lets say 1px to the right and 1 px to the down just re-draw the container with slice of the map of coords x3001 and width 2000px / y3001, width 2000px etc? Would it be good idea?
  3. ok but should i load for example whole 8000x8000 png file into my app? How do i display just part of it and render only for example 300x300 cutted piece of it?
  4. Im trying to wrap my brain around the internals of game like surviv.io. As i know it uses pixi.js for rendering. The whole map is enormous with many players doing their things in diffrent parts of it. How does it even work and renders so smoothly? How do I achieve similar effect in pixi? Let's say i want to put big game world into one container and control my player on only small rectangle of it while something is happening (monsters spawning etc) on other parts of game world? Could you please give some ideas, tutorials about it? The general idea i thought about is:
×
×
  • Create New...