|
@@ -228,14 +228,14 @@ class HNScenceManager {
|
|
|
runScene.addChild(pgContentP);
|
|
|
}
|
|
|
|
|
|
- let direct = 1//PG游戏横着放
|
|
|
- if (direct == this.PORTRAIT) {
|
|
|
- pgContentP.angle = 90
|
|
|
- pgContentP.setContentSize(runScene.getContentSize().height,runScene.getContentSize().width)//因为旋转了,宽高对调了
|
|
|
- } else {
|
|
|
+ let direct = 0
|
|
|
+ if (direct == this.PORTRAIT) {//PG游戏竖着放
|
|
|
pgContentP.setContentSize(750,1334);
|
|
|
let scale = runScene.getContentSize().height/1334;
|
|
|
pgContentP.setScale(scale);
|
|
|
+ } else {//PG游戏横着放
|
|
|
+ pgContentP.angle = 90
|
|
|
+ pgContentP.setContentSize(runScene.getContentSize().height,runScene.getContentSize().width)//因为旋转了,宽高对调了
|
|
|
}
|
|
|
gameNode.parent = pgContentP
|
|
|
pgContentP.setAnchorPoint(0.5, 0.5);
|