예제 #1
0
 protected GameObject(MinerGame game)
     : base(game)
 {
     Game    = game;
     Drawing = new DrawingComponent(this, game.SpriteBatch);
     Physics = new PhysicsComponent(this);
 }
예제 #2
0
        private void ParcourirDrawingComponent(ModelDoc2 mdlBase, DrawingComponent dcp, View vue, String nomEsquisse, Boolean afficher)
        {
            // Si le composant est Racine, on passe par le modele pour parcourir les fonctions
            // sinon ça ne marche pas
            if (dcp.Component.IsRoot())
            {
                dcp.View.ReferencedDocument.eParcourirFonctions(f => AppliquerOptions(mdlBase, f, vue, nomEsquisse, afficher), false);
            }
            else
            {
                dcp.Component.eParcourirFonctions(f => AppliquerOptions(mdlBase, f, vue, nomEsquisse, afficher), false);
            }

            try
            {
                if (dcp.GetChildrenCount() > 0)
                {
                    Object[] l = (object[])dcp.GetChildren();
                    foreach (DrawingComponent sdcp in l)
                    {
                        if (sdcp.Visible)
                        {
                            ParcourirDrawingComponent(mdlBase, sdcp, vue, nomEsquisse, afficher);
                        }
                    }
                }
            }
            catch (Exception e)
            {
                this.LogErreur(new Object[] { e });
            }
        }
예제 #3
0
 //Construtor
 public RINTCONS_VM(DrawingComponent drawingComponent)
 {
     ChangedTag        = false;
     _DrawingComponent = drawingComponent;
     BuildingName      = new StringBuilder(260);
     BuildingPath      = new StringBuilder(260);
     ReinforcingBar    = new List <double>();
     INITIAL_LOAD();
     CONSOLOS_LER();
     LoadReinforcingBarOptions();
     CarregarSimboloUnidades();
 }
예제 #4
0
파일: GameObject.cs 프로젝트: pecea/Miner
 protected GameObject()
 {
     Drawing = new DrawingComponent();
     Physics = new PhysicsComponent();
     Input   = new InputComponent();
 }
예제 #5
0
 public MainWindow()
 {
     InitializeComponent();
     drawingComponent = DrawableComponentCreator.CreateDrawableComponent(DrawableComponentTypes.TQSJan);
     WFHost.Child     = drawingComponent;
 }