コード例 #1
0
 public static void sys_map_option(StudioController game, bool param)
 {
     Studio.Map map;
     // set map option visible: param = 1/0
     map = Studio.Map.Instance;
     map.VisibleOption = param;
 }
コード例 #2
0
        public static void sys_fm_png(StudioController game, string param = "")
        {
            // set frame png, param = png file name, CharaStudio only

            var pngName = param.Trim();

            if (pngName != "")
            {
                if (!pngName.ToLower().EndsWith(".png"))
                {
                    pngName += ".png";
                }
                // load png in game scene folder if existed
                var pngInScene = Utils.combine_path(game.get_scene_dir(), game.sceneDir, pngName);
                if (File.Exists(pngInScene))
                {
                    var pngRevPath = Utils.combine_path("..", "studio", "scene", game.sceneDir, pngName);
                    game.scene_set_framefile(pngRevPath);
                    return;
                }
                // load png in game default background folder if existed
                var pngInDefault = Path.GetFullPath(Utils.combine_path(Application.dataPath, "..", "UserData", "frame", pngName));
                if (File.Exists(pngInDefault))
                {
                    game.scene_set_framefile(pngName);
                    return;
                }
            }
            // remove if param == "" or file not existed
            game.scene_set_framefile("");
        }
コード例 #3
0
 public StudioController() : base()
 {
     if (Instance != null)
     {
         throw new InvalidOperationException("Can only create one instance of Controller");
     }
     Instance = this;
 }
コード例 #4
0
ファイル: Utils.cs プロジェクト: hallongrotta/VNEngine-Sharp
        public static void sys_map_sun(StudioController game, int param)
        {
            // set sunLightType, param = sunLightType index, CharaStudio only
            var st  = new SunLightInfo.Info.Type[] { SunLightInfo.Info.Type.DayTime, SunLightInfo.Info.Type.Evening, SunLightInfo.Info.Type.Night };
            var map = Map.Instance;

            map.sunType = st[param];
        }
コード例 #5
0
ファイル: System.cs プロジェクト: hallongrotta/VNEngine-Sharp
 public static void sys_map(StudioController game, int param)
 {
     // set map
     if (param != game.studio_scene.map)
     {
         game.change_map_to(param);
     }
 }
コード例 #6
0
 public StudioController(List <Button_s> vnButtonsStart) : base()
 {
     if (Instance != null)
     {
         throw new InvalidOperationException("Can only create one instance of Controller");
     }
     this._vnButtons = vnButtonsStart;
     Instance        = this;
 }
コード例 #7
0
ファイル: System.cs プロジェクト: hallongrotta/VNEngine-Sharp
            public SystemData(StudioController game)
            {
                // export a dict contains all system status
                //from Studio import Studio
                //studio = Studio.Instance

                bgm = new BGM_s {
                    no = game.studio.bgmCtrl.no, play = game.studio.bgmCtrl.play
                };

                if (game.studio.outsideSoundCtrl.fileName != "")
                {
                    wav = new Wav_s {
                        fileName = game.studio.outsideSoundCtrl.fileName, play = game.studio.outsideSoundCtrl.play, repeat = game.studio.outsideSoundCtrl.repeat == BGMCtrl.Repeat.All
                    };
                }
                else
                {
                    wav = null;
                }
                map     = game.studio_scene.map;
                map_pos = game.studio_scene.caMap.pos;
                map_rot = game.studio_scene.caMap.rot;

                sun = game.studio_scene.sunLightType;


                map_opt = game.studio_scene.mapOption;

                bg_png = game.scene_get_bg_png_orig();

                fm_png = game.scene_get_framefile();


                var cl = game.studio_scene.charaLight;

                char_light = new CharLight_s {
                    rgbDiffuse = cl.color, cameraLightIntensity = cl.intensity, rot_y = cl.rot[0], rot_x = cl.rot[1], cameraLightShadow = cl.shadow
                };

                ace = System.ace;

                /* TODO
                 * if (game.isStudioNEO || game.isCharaStudio)
                 * {
                 *  if (extplugins.ExtPlugin.exists("NodesConstraints"))
                 *  {
                 *      if (is_ini_value_true("ExportSys_NodesConstraints"))
                 *      {
                 *          var pl_nodescon = extplugins.NodesConstraints();
                 *          pl_nodescon = pl_nodescon.GetSysSettingsText();
                 *      }
                 *  }
                 * }
                 */
            }
コード例 #8
0
 public void Apply(StudioController game, bool change_map = true)
 {
     sys_bgm(game, this);
     sys_wav(game, this);
     if (change_map)
     {
         sys_map(game, this);
     }
     sys_map_pos(game, this);
     sys_map_rot(game, this);
     sys_map_option(game, this.map_opt);
     sys_bg_png(game, this);
     sys_fm_png(game, this.fm_png);
     sys_char_light(game, this);
     if (!System.colorCorrection.Equals(colorCorrection))
     {
         System.colorCorrection = this.colorCorrection;
     }
 }
コード例 #9
0
ファイル: System.cs プロジェクト: hallongrotta/VNEngine-Sharp
            internal void Apply(StudioController game, bool change_map = true)
            {
                sys_bgm(game, this);
                sys_wav(game, this);

                if (change_map)
                {
                    sys_map(game, this);
                }

                sys_map_pos(game, this);
                sys_map_rot(game, this);
                map_sun(game, this);
                map_option(game, this);
                sys_bg_png(game, this);
                sys_fm_png(game, this);
                sys_char_light(game, this);
                if (!System.ace.Equals(ace))
                {
                    System.ace = this.ace;
                }
            }
コード例 #10
0
 public static void sys_map_light(StudioController game, bool param)
 {
     game.studio_scene.mapInfo.light = param;
 }
コード例 #11
0
ファイル: System.cs プロジェクト: hallongrotta/VNEngine-Sharp
 public static void sys_map(StudioController game, SystemData s)
 {
     sys_map(game, s.map);
 }
コード例 #12
0
ファイル: System.cs プロジェクト: hallongrotta/VNEngine-Sharp
 public static void sys_fm_png(StudioController game, SystemData param)
 {
     sys_fm_png(game, param.fm_png);
 }
コード例 #13
0
ファイル: System.cs プロジェクト: hallongrotta/VNEngine-Sharp
 public static void map_sun(StudioController game, SystemData param)
 {
     map_sun(game, param.sun);
 }