Can you do an isometric perspective with HTML5 ?

前端 未结 2 1500
暖寄归人
暖寄归人 2020-12-12 21:11

It is possible to do an isometric perspective with HTML5 ? It is with setTransform? Or does it exist another way?

Example:

2条回答
  •  佛祖请我去吃肉
    2020-12-12 22:01

    Well to make an isometric game its not so much as skewing the whole canvas, its more about the graphics you use. For example the tiles are generally h=w/2. So in a normal game you'd have a tile thats 32x32 in an isometric game you'd make it 32x16. Also the placement of tiles is a bit different to compensate for the angle.

    Short answer yes isometric games are fully possible using canvas. Look at Freeciv for an example of one.

    Another good place to ask on the specifics of isometric game creation would be https://gamedev.stackexchange.com/

提交回复
热议问题