Example #1
0
        public World(ShotTypeProvider typeProvider, PythonExecutor executor, int startframe, int endframe)
        {
            ShotTypeProvider = typeProvider;
            Executor         = executor;
            StartFrame       = startframe;
            EndFrame         = endframe;

            ShotModelProvider = new ShotModelDataProvider();
            PmxModel          = new CurtainFireModel(this);
            VmdSequence       = new CurtainFireSequence(this);

            foreach (var type in ShotTypeProvider.ShotTypeDict.Values)
            {
                type.InitWorld(this);
            }

            if (0 < StartFrame)
            {
                VmdSequence.AddPropertyKeyFrame(new VmdPropertyFrameData(0, false));
                VmdSequence.AddPropertyKeyFrame(new VmdPropertyFrameData(StartFrame, true));
            }

            ExportEvent += (sender, e) =>
            {
                PmxModel.Export(e.Script, e.PmxExportPath, ExportFileName, "by CurtainFireMakerPlugin");
                VmdSequence.Export(e.Script, e.VmdExportPath, ExportFileName);
            };
        }
Example #2
0
        internal World(Plugin plugin, string fileName)
        {
            Plugin = plugin;

            Scene    = Plugin.Scene;
            Config   = Plugin.Config;
            Executor = Plugin.PythonExecutor;

            ShotManager = new ShotGroupManager(this);
            PmxModel    = new CurtainFireModel(this);
            KeyFrames   = new CurtainFireMotion(this);

            ExportFileName = fileName;
            ModelName      = ExportFileName;
        }