-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Software Antics
committed
Apr 18, 2024
1 parent
82b5312
commit 654152a
Showing
13 changed files
with
61 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
FinalEngine.Editor.Common/Driver/Systems/EditorUpdateEntitySystem.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
// <copyright file="EditorUpdateEntitySystem.cs" company="Software Antics"> | ||
// Copyright (c) Software Antics. All rights reserved. | ||
// </copyright> | ||
|
||
namespace FinalEngine.Editor.Common.Driver.Systems; | ||
|
||
using System; | ||
using System.Collections.Generic; | ||
using System.Diagnostics.CodeAnalysis; | ||
using FinalEngine.ECS; | ||
using FinalEngine.ECS.Attributes; | ||
using FinalEngine.Input.Keyboards; | ||
using FinalEngine.Input.Mouses; | ||
|
||
[EntitySystemProcess(ExecutionType = GameLoopType.Update)] | ||
public sealed class EditorUpdateEntitySystem : EntitySystemBase | ||
{ | ||
private readonly IKeyboard keyboard; | ||
|
||
private readonly IMouse mouse; | ||
|
||
public EditorUpdateEntitySystem(IKeyboard keyboard, IMouse mouse) | ||
{ | ||
this.keyboard = keyboard ?? throw new ArgumentNullException(nameof(keyboard)); | ||
this.mouse = mouse ?? throw new ArgumentNullException(nameof(mouse)); | ||
} | ||
|
||
protected override void Process([NotNull] IEnumerable<Entity> entities) | ||
{ | ||
this.keyboard.Update(); | ||
this.mouse.Update(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
FinalEngine.Editor.Desktop/Extensions/ServiceCollectionExtensions.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// <copyright file="ServiceCollectionExtensions.cs" company="Software Antics"> | ||
// Copyright (c) Software Antics. All rights reserved. | ||
// </copyright> | ||
|
||
namespace FinalEngine.Editor.Desktop.Extensions; | ||
|
||
using System; | ||
using Microsoft.Extensions.DependencyInjection; | ||
|
||
public static class ServiceCollectionExtensions | ||
{ | ||
public static IServiceCollection AddEditorPlatform(this IServiceCollection services) | ||
{ | ||
ArgumentNullException.ThrowIfNull(services, nameof(services)); | ||
return services; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.