Jump to content

Weird Scaling problem


ekeimaja
 Share

Recommended Posts

in main.js is

new Phaser.Game(707,550, Phaser.AUTO, '');

That is size of that image.

 

in boot.js is

this.scale.scaleMode = Phaser.ScaleManager.NO_SCALE;

in game.js is

this.katu = this.game.add.tileSprite(0, 0, 707, 550, 'katu');

That road sprite should appear only once and slide downwards in constant speed. My other game, I have created with same template, works normally.

Link to comment
Share on other sites

main.js

new Phaser.Game(707,442, Phaser.AUTO, '');

boot.js

  create: function() {          this.scale.scaleMode = Phaser.ScaleManager.NO_SCALE;     this.physics.startSystem(Phaser.Physics.ARCADE);        this.state.start('preload');   }

preload.js is just load files and

this.scale.pageAlignHorizontally = true;

game1.js

create: function(){           this.katu = this.game.add.tileSprite(0, 0, 707, 442, 'katu');    },update: function(){         this.katu.tilePosition.y += 1;    }  
Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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