public void button7_Click(object sender, EventArgs e)
 {
     LevelObjectDescription rod = new LevelObjectDescription();
     rod.Pack = packs.packs[0];
     if (rod.createpropertieswindow(rod.Pack, tv) == System.Windows.Forms.DialogResult.OK)
     {
         rod.Pack.Attach(rod);
         FormMainPackExplorer.Instance.UpdateData();
     }
     if (sender == null) this.Close();
 }
Ejemplo n.º 2
0
        public static PivotObject LoadObject(string __name,
            Matrix? __deltaMatrix,
            bool __needMouseCast,
            bool __needBulletCast,
            PivotObjectDependType __dependType = PivotObjectDependType.Body)
        {
            var description = new LevelObjectDescription();
            description = PackList.Instance.GetObject(__name, description) as LevelObjectDescription;

            LevelObject loNew = ContentLoader.ContentLoader.LevelObjectFromDescription(description, PackList.Instance, GameEngine.Instance.Scene, __dependType);
            GameEngine.Instance.GraphicPipeleine.ProceedObject(loNew.renderaspect);

            loNew.useDeltaMatrix = __deltaMatrix != null && __deltaMatrix.HasValue;
            if (loNew.useDeltaMatrix)
                loNew.deltaMatrix = __deltaMatrix.Value;
            loNew._needMouseCast = __needMouseCast;
            loNew._needBulletCast = __needBulletCast;

            loNew.Update();
            return loNew;
        }