zoukankan      html  css  js  c++  java
  • 用flash builder创建手机项目以及发布app需要注意的细节

    1.在项目包与bin—debug同级建一个resource文件夹,放swf文件,xml配置文件,这个文件里的内容都是在最终发布App打包时要包含的,bin-debug中的资源文件包括swf文件,xml配置文件等是在调试时会调用的,所以即使resource文件夹与bin-debug中的资源大致相同,二者用途不同

    2.最好在GameModel中定义两个公共常量,在主类构造方法中赋值,方便项目中使用

    GameModel.getInstance().screenWidth = stage.fullScreenWidth;
    GameModel.getInstance().screenHeight = stage.fullScreenHeight;

    3.

    public function myPuzzleDictionary()
    {
    super();


    stage.setOrientation(StageOrientation.ROTATED_RIGHT);//设置了这个属性后,宽高可能会反过来,例如1280×800,可能会变为800×1280,相应的显示对象坐标位置就要调整
    // 支持 autoOrient
    stage.align = StageAlign.TOP_LEFT;
    stage.scaleMode = StageScaleMode.EXACT_FIT;

    stage.displayState = StageDisplayState.FULL_SCREEN;

    这几个舞台属性要设置一下

    4.src目录下 项目文件名+ -app.xml 这个文件打开,其中有4处需要设置,一是

    <!-- A universally unique application identifier. Must be unique across all AIR applications.
    Using a reverse DNS-style name as the id is recommended. (Eg. com.example.ExampleApplication.) Required. -->
    <id>net.4ggc.PuzzleDictionary</id>

    二是

    <!-- The name that is displayed in the AIR application installer.
    May have multiple values for each language. See samples or xsd schema file. Optional. -->
    <name>Puzzle Dictionary</name>

    三是

    <autoOrients>false</autoOrients>//设为false就不会横屏竖屏来回切换了(一般在108行)
    <fullScreen>true</fullScreen>
    <visible>true</visible>
    </initialWindow>

    四是

    <icon>
    <image36x36>assets/icon36.png</image36x36>
    <image48x48>assets/icon48.png</image48x48>
    <image72x72>assets/icon72.png</image72x72>
    </icon>

    //(一般在128行)发布app用的小图标,存放在src文件中的assets文件夹中

    5.菜单栏项目——导出发行版

  • 相关阅读:
    【Github】github图片显示不出
    【Linux】docker安装FastDFS
    【Github】问题解决:Failed to connect to github.com port 443: Operation timed out
    python生成1000w的mysql测试数据
    python 瀑布流
    django使用url路径组合搜索
    将规定的文件以及文件夹,压缩打包
    定期清理iis_log日志文件
    自己开发的python分页插件
    使用IO多路复用selectors模块写上传下载功能
  • 原文地址:https://www.cnblogs.com/kuailezoe/p/2945196.html
Copyright © 2011-2022 走看看