Skip to content

Commit

Permalink
Merge pull request #169 from Lacyway/abstract-prefix
Browse files Browse the repository at this point in the history
Prefix abstract classes with "Abstract"
  • Loading branch information
seionmoya authored Jan 8, 2025
2 parents b5ee3bb + 40db1b4 commit 09079b9
Show file tree
Hide file tree
Showing 101 changed files with 137 additions and 137 deletions.
22 changes: 11 additions & 11 deletions Documentation/fuyu-tutorial-mod.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ However, it is a **MUST** that you use either `Visual Studio Code` or
`Visual Studio 2022` (or newer). For writing script mods, I recommend using
`Visual Studio Code`. For advanced mods, use `Visual Studio 2022` (or newer).

Having prior experience with C# will definetly help, but is not required.
Having prior experience with C# will definitely help, but is not required.

### Setting up folder structure

Expand Down Expand Up @@ -113,7 +113,7 @@ using Fuyu.Common.IO;

namespace Senko.HelloWorld
{
public class HelloWorldMod : Mod
public class HelloWorldMod : AbstractMod
{
public override string Id { get; } = "Senko.HelloWorld";
public override string Name { get; } = "Senko - HelloWorld";
Expand Down Expand Up @@ -146,22 +146,22 @@ using Fuyu.Modding;
using Fuyu.Common.IO;
```

This imports things we can use in our mod. Some of them are required by `Mod`
This imports things we can use in our mod. Some of them are required by `AbstractMod`
to function.

```cs
public class HelloWorldMod : Mod
public class HelloWorldMod : AbstractMod
```

This is a `class` and also the heart of our mod. Here we can include
functionality to the mod. Think of `class` as a tiny program. It can depend on
other programs (inheritance).

```cs
: Mod
: AbstractMod
```

This means we inherit from `Mod`, telling the mod loader that this is the place
This means we inherit from `AbstractMod`, telling the mod loader that this is the place
to start looking for information of our mod.

```cs
Expand Down Expand Up @@ -216,7 +216,7 @@ tools and helpers from `Fuyu` and other mods when we need to.

```cs
{
// done loading the mod!
// done loading the !
return Task.CompletedTask;
}
```
Expand Down Expand Up @@ -244,7 +244,7 @@ using Fuyu.Common.IO;

namespace Senko.HelloWorld
{
public class HelloWorldMod : Mod
public class HelloWorldMod : AbstractMod
{
public override string Id { get; } = "Senko.HelloWorld";
public override string Name { get; } = "Senko - HelloWorld";
Expand Down Expand Up @@ -338,7 +338,7 @@ using Fuyu.Common.IO;

namespace Senko.HelloWorld
{
public class HelloWorldMod : Mod
public class HelloWorldMod : AbstractMod
{
public override string Id { get; } = "Senko.HelloWorld";
public override string Name { get; } = "Senko - HelloWorld";
Expand Down Expand Up @@ -373,7 +373,7 @@ using Fuyu.Common.IO;

namespace Senko.HelloWorld
{
public class HelloWorldMod : Mod
public class HelloWorldMod : AbstractMod
{
public override string Id { get; } = "Senko.HelloWorld";
public override string Name { get; } = "Senko - HelloWorld";
Expand Down Expand Up @@ -432,7 +432,7 @@ using Fuyu.Common.IO;

namespace Senko.HelloWorld
{
public class HelloWorldMod : Mod
public class HelloWorldMod : AbstractMod
{
public override string Id { get; } = "Senko.HelloWorld";
public override string Name { get; } = "Senko - HelloWorld";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@

namespace Fuyu.Backend.BSG.Networking
{
public abstract class ItemEventController<TEvent> : IItemEventController where TEvent : BaseItemEvent
public abstract class AbstractItemEventController<TEvent> : IItemEventController where TEvent : BaseItemEvent
{
public string Action { get; private set; }

public ItemEventController(string action)
public AbstractItemEventController(string action)
{
Action = action;
}
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.Core/Controllers/AccountGamesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Fuyu.Backend.Core.Controllers
{
public class AccountGamesController : CoreHttpController
public class AccountGamesController : AbstractCoreHttpController
{
public AccountGamesController() : base("/account/games")
{
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.Core/Controllers/AccountLogoutController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Fuyu.Backend.Core.Controllers
{
public class AccountLogoutController : CoreHttpController
public class AccountLogoutController : AbstractCoreHttpController
{
public AccountLogoutController() : base("/account/logout")
{
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.Core/Controllers/PingController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Fuyu.Backend.Core.Controllers
{
public class PingController : CoreHttpController
public class PingController : AbstractCoreHttpController
{
public PingController() : base("/ping")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@

namespace Fuyu.Backend.Core.Networking
{
public abstract class CoreHttpController : HttpController
public abstract class AbstractCoreHttpController : AbstractHttpController
{
protected CoreHttpController(Regex pattern) : base(pattern)
protected AbstractCoreHttpController(Regex pattern) : base(pattern)
{
// match dynamic paths
}

protected CoreHttpController(string path) : base(path)
protected AbstractCoreHttpController(string path) : base(path)
{
// match static paths
}
Expand All @@ -26,7 +26,7 @@ public override Task RunAsync(HttpContext context)
public abstract Task RunAsync(CoreHttpContext context);
}

public abstract class CoreHttpController<TRequest> : CoreHttpController where TRequest : class
public abstract class CoreHttpController<TRequest> : AbstractCoreHttpController where TRequest : class
{
protected CoreHttpController(Regex pattern) : base(pattern)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class AchievementListController : EftHttpController
public class AchievementListController : AbstractEftHttpController
{
public AchievementListController() : base("/client/achievement/list")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class AchievementStatisticController : EftHttpController
public class AchievementStatisticController : AbstractEftHttpController
{
public AchievementStatisticController() : base("/client/achievement/statistic")
{
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.EFT/Controllers/Http/BuildsListController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class BuildsListController : EftHttpController
public class BuildsListController : AbstractEftHttpController
{
private readonly ResponseBody<BuildsListResponse> _response;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class CheckVersionController : EftHttpController
public class CheckVersionController : AbstractEftHttpController
{
public CheckVersionController() : base("/client/checkVersion")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public partial class ClientItemsPriceController : EftHttpController
public partial class ClientItemsPriceController : AbstractEftHttpController
{
[GeneratedRegex(@"^/client/items/prices(/(?<traderId>[A-Za-z0-9]+))?$")]
private static partial Regex PathExpression();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class CustomizationController : EftHttpController
public class CustomizationController : AbstractEftHttpController
{
public CustomizationController() : base("/client/customization")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class CustomizationStorageController : EftHttpController
public class CustomizationStorageController : AbstractEftHttpController
{
public CustomizationStorageController() : base("/client/customization/storage")
{
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.EFT/Controllers/Http/FilesController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public partial class FilesController : EftHttpController
public partial class FilesController : AbstractEftHttpController
{
[GeneratedRegex(@"^/files/(?<path>.+)$")]
private static partial Regex PathExpression();
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.EFT/Controllers/Http/FriendListController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class FriendListController : EftHttpController
public class FriendListController : AbstractEftHttpController
{
public FriendListController() : base("/client/friend/list")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class FriendRequestListInboxController : EftHttpController
public class FriendRequestListInboxController : AbstractEftHttpController
{
public FriendRequestListInboxController() : base("/client/friend/request/list/inbox")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class FriendRequestListOutboxController : EftHttpController
public class FriendRequestListOutboxController : AbstractEftHttpController
{
public FriendRequestListOutboxController() : base("/client/friend/request/list/outbox")
{
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.EFT/Controllers/Http/GameConfigController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GameConfigController : EftHttpController
public class GameConfigController : AbstractEftHttpController
{
public GameConfigController() : base("/client/game/config")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GameKeepaliveController : EftHttpController
public class GameKeepaliveController : AbstractEftHttpController
{
public GameKeepaliveController() : base("/client/game/keepalive")
{
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.EFT/Controllers/Http/GameLogoutController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GameLogoutController : EftHttpController
public class GameLogoutController : AbstractEftHttpController
{
public GameLogoutController() : base("/client/game/logout")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GameProfileListController : EftHttpController
public class GameProfileListController : AbstractEftHttpController
{
public GameProfileListController() : base("/client/game/profile/list")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GameProfileNicknameReservedController : EftHttpController
public class GameProfileNicknameReservedController : AbstractEftHttpController
{
public GameProfileNicknameReservedController() : base("/client/game/profile/nickname/reserved")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GameProfileSelectController : EftHttpController
public class GameProfileSelectController : AbstractEftHttpController
{
public GameProfileSelectController() : base("/client/game/profile/select")
{
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.EFT/Controllers/Http/GameStartController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GameStartController : EftHttpController
public class GameStartController : AbstractEftHttpController
{
public GameStartController() : base("/client/game/start")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GameVersionValidateController : EftHttpController
public class GameVersionValidateController : AbstractEftHttpController
{
public GameVersionValidateController() : base("/client/game/version/validate")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GetMetricsConfigController : EftHttpController
public class GetMetricsConfigController : AbstractEftHttpController
{
public GetMetricsConfigController() : base("/client/getMetricsConfig")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public partial class GetTraderAssortController : EftHttpController
public partial class GetTraderAssortController : AbstractEftHttpController
{
[GeneratedRegex("/client/trading/api/getTraderAssort/(?<traderId>[A-Za-z0-9]+)")]
private static partial Regex PathExpression();
Expand Down
2 changes: 1 addition & 1 deletion Fuyu.Backend.EFT/Controllers/Http/GlobalsController.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class GlobalsController : EftHttpController
public class GlobalsController : AbstractEftHttpController
{
public GlobalsController() : base("/client/globals")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class HandbookTemplatesController : EftHttpController
public class HandbookTemplatesController : AbstractEftHttpController
{
public HandbookTemplatesController() : base("/client/handbook/templates")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class HideoutAreasController : EftHttpController
public class HideoutAreasController : AbstractEftHttpController
{
public HideoutAreasController() : base("/client/hideout/areas")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class HideoutCustomizationOfferListController : EftHttpController
public class HideoutCustomizationOfferListController : AbstractEftHttpController
{
public HideoutCustomizationOfferListController() : base("/client/hideout/customization/offer/list")
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace Fuyu.Backend.EFT.Controllers.Http
{
public class HideoutProductionRecipesController : EftHttpController
public class HideoutProductionRecipesController : AbstractEftHttpController
{
public HideoutProductionRecipesController() : base("/client/hideout/production/recipes")
{
Expand Down
Loading

0 comments on commit 09079b9

Please sign in to comment.