Tiled Backgrounds & Normal Maps

0 favourites
  • 10 posts
From the Asset Store
A template which allows you to customise the controls of your game.
  • I've tried searching for this, but nothing has come up.

    Please see the attached:

    CAPX

    In the CAPX I have a tiled background with a normal map on the left, and a standard sprite on the right.

    I can't seem to get normal maps working as expected on tiled backgrounds. It all appears to be inverted. If you have a look at the code, the tiled and the sprite code is the same, however they respond differently.

    Also, I noticed that when I scaled the tiled background, in the editor it appears to shrink down and look odd, however at runtime it looks fine. It's just the inversion that is really the problem.

    I've tried looking it up. Are tiled backgrounds just incompatible with normal maps?

    I can work just fine with sprites, but figured it would be better to use a more memory efficient tiled background.

    Hope I've made sense!

  • Just read a bit of the manual, and it says that rather than applying effects to multiple objects, I should apply it to a layer.

    Any suggestions on how I should apply normalmaps to a layer?

    I've tried:

    ((Mouse.X-scrollx)/LayoutWidth)*100

    ((Mouse.Y-scrolly)/LayoutHeight)*100

    But as expected, it did not work :(

  • can works if you put -512 for the height of your tiledbackground with bumpmaping

  • As far as I can tell, that won't help me if I plan on making the tiles any larger. Also, it's now upside down.

    Have I misunderstood. You mean to actually change the Y scale of the object to -512 in the layout editor?

  • anata Broken link:(

  • it's good now

  • Thanks anata,

    but that can't be the solution. Is this a bug Ashley?

    Anata, in the version you sent me, if you drag select the tiled backgrounds, and then scale the right hand side so it's half the size it was previously, and then try it again, does it work for you? For me, the light no longer follows the mouse.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Does anyone have any wise words on how you apply and make use of a normal map on a layer?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)