void Awake()
{
//设置屏幕正方向在Home键右边
Screen.orientation = ScreenOrientation.LandscapeRight;
}
void Start ()
{
//设置屏幕自动旋转, 并置支持的方向
Screen.orientation = ScreenOrientation.AutoRotation;
Screen.autorotateToLandscapeLeft = true;
Screen.autorotateToLandscapeRight = true;
Screen.autorotateToPortrait = false;
Screen.autorotateToPortraitUpsideDown = false;
}
安卓的屏幕控制方向受安卓源生开发activity的XML配置属性设置决定 1-2楼所说的是unity帮你封装好的设置 对应你开发的主activity屏幕设置方向 如果你的游戏不止一个activity unity的设置不能全部设置了 需要打开安卓工程的androidmanifestxml进行设置 建议楼主看一些安卓开发的基本知识 unity并不是万能的 不能一直依赖插件 有些SDK接入是java接口 设置屏幕转向就不能用unity了
Photoshop|
Dreamweaver|
SVG|
WebGL|
Visual Studio|
PowerDesigner|
Eclipse|
Git|
Apache Ant|
Atom|
Composer|
CodeSmith|
Flex|
Gradle|
Maven|
Sublime Text3|
SVN|
Tableau|
Vim|
Chrome开发者工具|
OpenGL|
Unity|
Direct3D|
用户登录
还没有账号?立即注册
用户注册
投稿取消
| 文章分类: |
|
还能输入300字
上传中....
蜗牛也是牛53258011