//// todo: rewrite public HeroEditor2(String filePath, TableDataSet tableDataSet) //{ // _dataSet = tableDataSet; // _filePath = filePath; // _hero = UnitHelpFunctions.OpenCharacterFile(_dataSet, _filePath); // if (_hero.IsGood) // { // _itemFunctions = new UnitHelpFunctions(_dataSet); // _itemFunctions.LoadCharacterValues(_hero); // _wrapper = new UnitWrapper(tableDataSet, _hero); // InitializeComponent(); // } //} private void HeroEditor2_Load(object sender, EventArgs e) { string path = Path.Combine(Config.HglDir, @"data\uix\xml\"); AtlasImageLoader loader = new AtlasImageLoader(); loader.LoadAtlas(path + "skilltree_atlas.xml"); loader.LoadAtlas(path + "skillpanel_atlas.xml"); InitSkillTree(loader); InitSkillPanel(loader); }
public void SetBitmaps(FileManager fileManager, HGLWindowStyle windowStyle) { AtlasImageLoader loader; loader = new AtlasImageLoader(); loader.LoadAtlas(@"data\uix\xml\main_atlas.xml", fileManager); List <Bitmap> imageList = new List <Bitmap>(); imageList.Clear(); imageList.Add(loader.GetImage(windowStyle + "_1_TL")); imageList.Add(loader.GetImage(windowStyle + "_2_TM")); imageList.Add(loader.GetImage(windowStyle + "_3_TR")); imageList.Add(loader.GetImage(windowStyle + "_4_ML")); imageList.Add(loader.GetImage(windowStyle + "_5_MM")); imageList.Add(loader.GetImage(windowStyle + "_6_MR")); imageList.Add(loader.GetImage(windowStyle + "_7_BL")); imageList.Add(loader.GetImage(windowStyle + "_8_BM")); imageList.Add(loader.GetImage(windowStyle + "_9_BR")); SetBitmaps(imageList); loader.ClearImageList(); imageList.Clear(); }
public AnimationTestForm(FileManager fileManager) { InitializeComponent(); animations = new List <string>(); animations.Add("health anim "); animations.Add("power anim "); loader = new AtlasImageLoader(); loader.LoadAtlas(@"data\uix\xml\main_new_atlas.xml", fileManager); handler = new AnimationHandler(); handler.Speed = (int)numericUpDown1.Value; handler.NewFrameEvent += new NewFrame(handler_NewFrameEvent); handler.AddOverlay(loader.GetImage("meter mask")); handler.AddOverlay(loader.GetImage("health meter")); comboBox1.DataSource = animations; }