コード例 #1
0
ファイル: ShipEditorWorld.cs プロジェクト: gusmanb/Mir
        public ShipEditorWorld(
            IFactory factory, 
            I2DRenderUtilities twoDRenderUtilities, 
            IAssetManagerProvider assetManagerProvider, 
            IShipTool[] shipTools)
        {
            this.Entities = new List<IEntity>();

            this.m_2DRenderUtilities = twoDRenderUtilities;
            this.m_AssetManager = assetManagerProvider.GetAssetManager();
            this.m_ShipTools = shipTools;
            this.m_DefaultFont = this.m_AssetManager.Get<FontAsset>("font.Default");

            this.m_Ship = factory.CreateShip();

            this.m_ShipEditorEntity = factory.CreateShipEditorEntity(this.m_Ship);

            this.Entities.Add(this.m_ShipEditorEntity);
        }
コード例 #2
0
ファイル: ShipEditorEntity.cs プロジェクト: gusmanb/Mir
        public ShipEditorEntity(
            IAssetManagerProvider assetManagerProvider,
            I2DRenderUtilities twoRenderUtilities,
            I3DRenderUtilities threeRenderUtilities,
            IGridRenderer gridRenderer, 
            ICollision collision,
            Ship ship)
        {
            this.m_DefaultFont = assetManagerProvider.GetAssetManager().Get<FontAsset>("font.Default");
            this.m_2DRenderUtilities = twoRenderUtilities;
            this.m_3DRenderUtilities = threeRenderUtilities;
            this.m_GridRenderer = gridRenderer;
            this.m_Collision = collision;
            this.m_Ship = ship;

            this.m_PreviewRotation = 0;

            this.HorizontalRange = 30;
            this.VerticalRange = 30;
            this.VerticalSelection = 3;

            this.UpdateShipVisibilityCull();
        }