diff --git a/sources/ClientRealm/API/Unreal/ClientUnrealAPIBase.uc b/sources/ClientRealm/API/Unreal/ClientUnrealAPI.uc similarity index 91% rename from sources/ClientRealm/API/Unreal/ClientUnrealAPIBase.uc rename to sources/ClientRealm/API/Unreal/ClientUnrealAPI.uc index 5c0893d..388e9b3 100644 --- a/sources/ClientRealm/API/Unreal/ClientUnrealAPIBase.uc +++ b/sources/ClientRealm/API/Unreal/ClientUnrealAPI.uc @@ -18,12 +18,12 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class ClientUnrealAPIBase extends UnrealAPIBase +class ClientUnrealAPI extends UnrealAPI abstract; var protected bool initialized; -var public InteractionAPIBase interaction; +var public InteractionAPI interaction; public function Initialize(class adapterClass) { @@ -34,7 +34,7 @@ public function Initialize(class adapterClass) if (adapterClass == none) { return; } - interaction = InteractionAPIBase(_.memory.Allocate( + interaction = InteractionAPI(_.memory.Allocate( adapterClass.default.clientInteractionAPIClass)); } diff --git a/sources/ClientRealm/API/Unreal/InteractionAPI/InteractionAPIBase.uc b/sources/ClientRealm/API/Unreal/InteractionAPI/InteractionAPI.uc similarity index 97% rename from sources/ClientRealm/API/Unreal/InteractionAPI/InteractionAPIBase.uc rename to sources/ClientRealm/API/Unreal/InteractionAPI/InteractionAPI.uc index 3c5e9b6..472f0d7 100644 --- a/sources/ClientRealm/API/Unreal/InteractionAPI/InteractionAPIBase.uc +++ b/sources/ClientRealm/API/Unreal/InteractionAPI/InteractionAPI.uc @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class InteractionAPIBase extends AcediaObject; +class InteractionAPI extends AcediaObject; /** * Called before rendering, when `Interaction`s receive their `PreRender()` diff --git a/sources/ClientRealm/ClientAcediaAdapter.uc b/sources/ClientRealm/ClientAcediaAdapter.uc index f866c2e..69ed40e 100644 --- a/sources/ClientRealm/ClientAcediaAdapter.uc +++ b/sources/ClientRealm/ClientAcediaAdapter.uc @@ -22,11 +22,11 @@ class ClientAcediaAdapter extends AcediaAdapter abstract; -var public const class clientUnrealAPIClass; -var public const class clientInteractionAPIClass; +var public const class clientUnrealAPIClass; +var public const class clientInteractionAPIClass; defaultproperties { - clientUnrealAPIClass = class'ClientUnrealAPI' - clientInteractionAPIClass = class'InteractionAPI' + clientUnrealAPIClass = class'KF1_ClientUnrealAPI' + clientInteractionAPIClass = class'KF1_InteractionAPI' } \ No newline at end of file diff --git a/sources/ClientRealm/ClientGlobal.uc b/sources/ClientRealm/ClientGlobal.uc index 37a481c..c1c3bfc 100644 --- a/sources/ClientRealm/ClientGlobal.uc +++ b/sources/ClientRealm/ClientGlobal.uc @@ -25,7 +25,7 @@ class ClientGlobal extends CoreGlobal; // main instance in this variable's default value. var protected ClientGlobal myself; -var public ClientUnrealAPIBase unreal; +var public ClientUnrealAPI unreal; var private LoggerAPI.Definition fatBadAdapterClass, errNoInteraction; @@ -65,7 +65,7 @@ protected function Initialize() } // Create APIs _ = class'Global'.static.GetInstance(); - unreal = ClientUnrealAPIBase( + unreal = ClientUnrealAPI( _.memory.Allocate(clientAdapterClass.default.clientUnrealAPIClass)); unreal.Initialize(clientAdapterClass); // Create `AcediaInteraction` diff --git a/sources/CoreRealm/API/SideEffects/SideEffectAPI.uc b/sources/CoreRealm/API/SideEffects/SideEffectAPI.uc index 540ff12..ed4ff2e 100644 --- a/sources/CoreRealm/API/SideEffects/SideEffectAPI.uc +++ b/sources/CoreRealm/API/SideEffects/SideEffectAPI.uc @@ -1,6 +1,6 @@ /** - * Standard implementation for simple API for managing a list of - * `SideEffect` info objects: can add, remove, return all and by package. + * Base class for simple API for managing a list of `SideEffect` info + * objects: can add, remove, return all and by package. * Copyright 2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -18,97 +18,58 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class SideEffectAPI extends SideEffectAPIBase; +class SideEffectAPI extends AcediaObject + abstract; -var private array activeSideEffects; - -public function array GetAll() -{ - local int i; - - for (i = 0; i < activeSideEffects.length; i += 1) { - activeSideEffects[i].NewRef(); - } - return activeSideEffects; -} - -public function SideEffect GetClass(class sideEffectClass) -{ - local int i; - - if (sideEffectClass == none) { - return none; - } - for (i = 0; i < activeSideEffects.length; i += 1) - { - if (activeSideEffects[i].class == sideEffectClass) - { - activeSideEffects[i].NewRef(); - return activeSideEffects[i]; - } - } - return none; -} - -public function array GetFromPackage(BaseText packageName) -{ - local int i; - local Text nextPackage; - local array result; - - if (packageName == none) { - return result; - } - for (i = 0; i < activeSideEffects.length; i += 1) - { - nextPackage = activeSideEffects[i].GetPackage(); - if (nextPackage.Compare(packageName, SCASE_INSENSITIVE)) - { - activeSideEffects[i].NewRef(); - result[result.length] = activeSideEffects[i]; - } - _.memory.Free(nextPackage); - } - return result; -} +/** + * Returns all so far registered `SideEffect`s. + * + * @return Array of all registered `SideEffect`s. + */ +public function array GetAll(); -public function bool Add(SideEffect newSideEffect) -{ - local int i; +/** + * Returns active `SideEffect` instance of the specified class + * `sideEffectClass`. + * + * @param sideEffectClass Class of side effect to return active instance of. + * @return Active `SideEffect` instance of the specified class + * `sideEffectClass`. + * `none` if either `sideEffectClass` is `none` or side effect of such + * class is not currently active. + */ +public function SideEffect GetClass(class sideEffectClass); - if (newSideEffect == none) { - return false; - } - for (i = 0; i < activeSideEffects.length; i += 1) - { - if (activeSideEffects[i].class == newSideEffect.class) { - return false; - } - } - newSideEffect.NewRef(); - activeSideEffects[activeSideEffects.length] = newSideEffect; - return true; -} +/** + * Returns all so far registered `SideEffect`s from a package `packageName` + * (case insensitive). + * + * @param packageName Name of the package, in `SideEffect`s from which we are + * interested. Must be not `none`. + * @return Array of all registered `SideEffect`s from a package `packageName`. + * If `none`, returns an empty array. + */ +public function array GetFromPackage(BaseText packageName); -public function bool RemoveClass( - class sideEffectClass) -{ - local int i; +/** + * Registers a new `SideEffect` object as active. + * + * @param newSideEffect Instance of some `SideEffect` class to register as + * active side effect. Must not be `none`. + * @return `true` if new side effect was added and `false` otherwise. + */ +public function bool Add(SideEffect newSideEffect); - if (sideEffectClass == none) { - return false; - } - for (i = 0; i < activeSideEffects.length; i += 1) - { - if (activeSideEffects[i].class == sideEffectClass) - { - _.memory.Free(activeSideEffects[i]); - activeSideEffects.Remove(i, 1); - return true; - } - } - return false; -} +/** + * Removes `SideEffect` of the specified sub-class from the list of active + * side effects. + * + * @param sideEffectClass Class of the side effect to remove. + * @return `true` if some side effect was removed as a result of this operation + * and `false` otherwise (even if there was no side effect of specified + * class to begin with). + */ +public function bool RemoveClass(class sideEffectClass); defaultproperties { diff --git a/sources/CoreRealm/API/SideEffects/SideEffectAPIBase.uc b/sources/CoreRealm/API/SideEffects/SideEffectAPIBase.uc deleted file mode 100644 index 14718ea..0000000 --- a/sources/CoreRealm/API/SideEffects/SideEffectAPIBase.uc +++ /dev/null @@ -1,76 +0,0 @@ -/** - * Base class for simple API for managing a list of `SideEffect` info - * objects: can add, remove, return all and by package. - * Copyright 2022 Anton Tarasenko - *------------------------------------------------------------------------------ - * This file is part of Acedia. - * - * Acedia is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, version 3 of the License, or - * (at your option) any later version. - * - * Acedia is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with Acedia. If not, see . - */ -class SideEffectAPIBase extends AcediaObject - abstract; - -/** - * Returns all so far registered `SideEffect`s. - * - * @return Array of all registered `SideEffect`s. - */ -public function array GetAll(); - -/** - * Returns active `SideEffect` instance of the specified class - * `sideEffectClass`. - * - * @param sideEffectClass Class of side effect to return active instance of. - * @return Active `SideEffect` instance of the specified class - * `sideEffectClass`. - * `none` if either `sideEffectClass` is `none` or side effect of such - * class is not currently active. - */ -public function SideEffect GetClass(class sideEffectClass); - -/** - * Returns all so far registered `SideEffect`s from a package `packageName` - * (case insensitive). - * - * @param packageName Name of the package, in `SideEffect`s from which we are - * interested. Must be not `none`. - * @return Array of all registered `SideEffect`s from a package `packageName`. - * If `none`, returns an empty array. - */ -public function array GetFromPackage(BaseText packageName); - -/** - * Registers a new `SideEffect` object as active. - * - * @param newSideEffect Instance of some `SideEffect` class to register as - * active side effect. Must not be `none`. - * @return `true` if new side effect was added and `false` otherwise. - */ -public function bool Add(SideEffect newSideEffect); - -/** - * Removes `SideEffect` of the specified sub-class from the list of active - * side effects. - * - * @param sideEffectClass Class of the side effect to remove. - * @return `true` if some side effect was removed as a result of this operation - * and `false` otherwise (even if there was no side effect of specified - * class to begin with). - */ -public function bool RemoveClass(class sideEffectClass); - -defaultproperties -{ -} \ No newline at end of file diff --git a/sources/CoreRealm/API/UnrealAPI/UnrealAPIBase.uc b/sources/CoreRealm/API/UnrealAPI/UnrealAPI.uc similarity index 99% rename from sources/CoreRealm/API/UnrealAPI/UnrealAPIBase.uc rename to sources/CoreRealm/API/UnrealAPI/UnrealAPI.uc index a62b8db..604bec6 100644 --- a/sources/CoreRealm/API/UnrealAPI/UnrealAPIBase.uc +++ b/sources/CoreRealm/API/UnrealAPI/UnrealAPI.uc @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class UnrealAPIBase extends AcediaObject +class UnrealAPI extends AcediaObject abstract; /** diff --git a/sources/CoreRealm/AcediaAdapter.uc b/sources/CoreRealm/AcediaAdapter.uc index 56a0f2d..676b4be 100644 --- a/sources/CoreRealm/AcediaAdapter.uc +++ b/sources/CoreRealm/AcediaAdapter.uc @@ -35,9 +35,9 @@ class AcediaAdapter extends AcediaObject * specify desired `AcediaAdapter` before loading server/client core. */ -var public const class sideEffectAPIClass; +var public const class sideEffectAPIClass; defaultproperties { - sideEffectAPIClass = class'SideEffectAPI' + sideEffectAPIClass = class'KF1_SideEffectAPI' } \ No newline at end of file diff --git a/sources/CoreRealm/CoreGlobal.uc b/sources/CoreRealm/CoreGlobal.uc index 577aa40..d14d09f 100644 --- a/sources/CoreRealm/CoreGlobal.uc +++ b/sources/CoreRealm/CoreGlobal.uc @@ -24,7 +24,7 @@ class CoreGlobal extends Object; var protected bool initialized; var protected class adapterClass; -var public SideEffectAPIBase sideEffects; +var public SideEffectAPI sideEffects; var private LoggerAPI.Definition fatNoAdapterClass; diff --git a/sources/CoreRealm/SideEffects.uc b/sources/CoreRealm/SideEffects.uc index 53ea3dd..8ad922a 100644 --- a/sources/CoreRealm/SideEffects.uc +++ b/sources/CoreRealm/SideEffects.uc @@ -20,7 +20,7 @@ * along with Acedia. If not, see . */ class SideEffects extends AcediaObject - dependson(BroadcastAPIBase) + dependson(BroadcastAPI) abstract config(AcediaSystem); @@ -95,7 +95,7 @@ var public const config bool allowReplacingDamageTypes; * Acedia and if you do not have a reason to forbid that (for example, for mod * compatibility reasons), you should set this value at `BHIJ_Root`. */ -var public const config BroadcastAPIBase.InjectionLevel broadcastHandlerInjectionLevel; +var public const config BroadcastAPI.InjectionLevel broadcastHandlerInjectionLevel; defaultproperties { diff --git a/sources/Gameplay/KF1Frontend/BaseImplementation/EKFInventory.uc b/sources/Gameplay/KF1Frontend/BaseImplementation/EKFInventory.uc index 257bff0..cff004b 100644 --- a/sources/Gameplay/KF1Frontend/BaseImplementation/EKFInventory.uc +++ b/sources/Gameplay/KF1Frontend/BaseImplementation/EKFInventory.uc @@ -241,7 +241,7 @@ private function KFWeapon GetByRootWithDualRole( Inventory inventoryChain, InventoryAPI.DualWieldingRole requiredRole) { - local InventoryAPIBase api; + local InventoryAPI api; local class nextWeaponClass; local class itemRoot, nextRoot; api = _server.unreal.inventory; diff --git a/sources/KFRealm/Client/API/Unreal/InteractionAPI/InteractionAPI.uc b/sources/KFRealm/Client/API/Unreal/InteractionAPI/KF1_InteractionAPI.uc similarity index 95% rename from sources/KFRealm/Client/API/Unreal/InteractionAPI/InteractionAPI.uc rename to sources/KFRealm/Client/API/Unreal/InteractionAPI/KF1_InteractionAPI.uc index 9fc49ca..4e38377 100644 --- a/sources/KFRealm/Client/API/Unreal/InteractionAPI/InteractionAPI.uc +++ b/sources/KFRealm/Client/API/Unreal/InteractionAPI/KF1_InteractionAPI.uc @@ -1,5 +1,5 @@ /** - * Default Acedia implementation for `InteractionAPIBase`. + * Default Acedia implementation for `InteractionAPI`. * Copyright 2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class InteractionAPI extends InteractionAPIBase; +class KF1_InteractionAPI extends InteractionAPI; /* SIGNAL */ public function Interaction_OnRender_Slot OnPreRender(AcediaObject receiver) diff --git a/sources/KFRealm/Client/API/Unreal/ClientUnrealAPI.uc b/sources/KFRealm/Client/API/Unreal/KF1_ClientUnrealAPI.uc similarity index 96% rename from sources/KFRealm/Client/API/Unreal/ClientUnrealAPI.uc rename to sources/KFRealm/Client/API/Unreal/KF1_ClientUnrealAPI.uc index 7e54014..8ca1be6 100644 --- a/sources/KFRealm/Client/API/Unreal/ClientUnrealAPI.uc +++ b/sources/KFRealm/Client/API/Unreal/KF1_ClientUnrealAPI.uc @@ -1,5 +1,5 @@ /** - * Acedia's default implementation for `ClientUnrealAPIBase`. + * Acedia's default implementation for `ClientUnrealAPI. * Copyright 2021-2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class ClientUnrealAPI extends ClientUnrealAPIBase; +class KF1_ClientUnrealAPI extends ClientUnrealAPI; var private LoggerAPI.Definition fatalNoStalker; diff --git a/sources/KFRealm/Core/KF1_SideEffectAPI.uc b/sources/KFRealm/Core/KF1_SideEffectAPI.uc new file mode 100644 index 0000000..6bd78d2 --- /dev/null +++ b/sources/KFRealm/Core/KF1_SideEffectAPI.uc @@ -0,0 +1,115 @@ +/** + * Standard implementation for simple API for managing a list of + * `SideEffect` info objects: can add, remove, return all and by package. + * Copyright 2022 Anton Tarasenko + *------------------------------------------------------------------------------ + * This file is part of Acedia. + * + * Acedia is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, version 3 of the License, or + * (at your option) any later version. + * + * Acedia is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with Acedia. If not, see . + */ +class KF1_SideEffectAPI extends SideEffectAPI; + +var private array activeSideEffects; + +public function array GetAll() +{ + local int i; + + for (i = 0; i < activeSideEffects.length; i += 1) { + activeSideEffects[i].NewRef(); + } + return activeSideEffects; +} + +public function SideEffect GetClass(class sideEffectClass) +{ + local int i; + + if (sideEffectClass == none) { + return none; + } + for (i = 0; i < activeSideEffects.length; i += 1) + { + if (activeSideEffects[i].class == sideEffectClass) + { + activeSideEffects[i].NewRef(); + return activeSideEffects[i]; + } + } + return none; +} + +public function array GetFromPackage(BaseText packageName) +{ + local int i; + local Text nextPackage; + local array result; + + if (packageName == none) { + return result; + } + for (i = 0; i < activeSideEffects.length; i += 1) + { + nextPackage = activeSideEffects[i].GetPackage(); + if (nextPackage.Compare(packageName, SCASE_INSENSITIVE)) + { + activeSideEffects[i].NewRef(); + result[result.length] = activeSideEffects[i]; + } + _.memory.Free(nextPackage); + } + return result; +} + +public function bool Add(SideEffect newSideEffect) +{ + local int i; + + if (newSideEffect == none) { + return false; + } + for (i = 0; i < activeSideEffects.length; i += 1) + { + if (activeSideEffects[i].class == newSideEffect.class) { + return false; + } + } + newSideEffect.NewRef(); + activeSideEffects[activeSideEffects.length] = newSideEffect; + return true; +} + +public function bool RemoveClass( + class sideEffectClass) +{ + local int i; + + if (sideEffectClass == none) { + return false; + } + for (i = 0; i < activeSideEffects.length; i += 1) + { + if (activeSideEffects[i].class == sideEffectClass) + { + _.memory.Free(activeSideEffects[i]); + activeSideEffects.Remove(i, 1); + return true; + } + } + return false; +} + +defaultproperties +{ +} \ No newline at end of file diff --git a/sources/KFRealm/Server/Time/ServerTimeAPI.uc b/sources/KFRealm/Server/Time/KF1_ServerTimeAPI.uc similarity index 94% rename from sources/KFRealm/Server/Time/ServerTimeAPI.uc rename to sources/KFRealm/Server/Time/KF1_ServerTimeAPI.uc index 1461311..252d83a 100644 --- a/sources/KFRealm/Server/Time/ServerTimeAPI.uc +++ b/sources/KFRealm/Server/Time/KF1_ServerTimeAPI.uc @@ -1,5 +1,5 @@ /** - * Acedia's default `ServerTimeAPIBase` API implementation + * Acedia's default `ServerTimeAPI` API implementation * Copyright 2021-2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class ServerTimeAPI extends ServerTimeAPIBase; +class KF1_ServerTimeAPI extends ServerTimeAPI; public function Timer NewTimer( optional float interval, diff --git a/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastEventsObserver.uc b/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastEventsObserver.uc index d220408..0f6f0ef 100644 --- a/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastEventsObserver.uc +++ b/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastEventsObserver.uc @@ -22,7 +22,7 @@ * along with Acedia. If not, see . */ class BroadcastEventsObserver extends Engine.BroadcastHandler - dependson(BroadcastAPIBase) + dependson(BroadcastAPI) config(AcediaSystem); // Forcing Acedia's own `BroadcastHandler` is rather invasive and might be @@ -30,7 +30,7 @@ class BroadcastEventsObserver extends Engine.BroadcastHandler // To alleviate this issue Acedia allows server admins to control how it's // `BroadcastHandler` is injected. Do note however that anything other than // `BHIJ_Root` can lead to issues with Acedia's features. -var private BroadcastAPIBase.InjectionLevel usedInjectionLevel; +var private BroadcastAPI.InjectionLevel usedInjectionLevel; /** * To understand how what our broadcast handler does, let us first explain diff --git a/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastSideEffect.uc b/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastSideEffect.uc index 541c53c..0a136d7 100644 --- a/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastSideEffect.uc +++ b/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastSideEffect.uc @@ -23,10 +23,9 @@ * along with Acedia. If not, see . */ class BroadcastSideEffect extends SideEffect - dependson(BroadcastAPIBase); + dependson(BroadcastAPI); -public final function Initialize( - BroadcastAPIBase.InjectionLevel usedInjectionLevel) +public final function Initialize(BroadcastAPI.InjectionLevel usedInjectionLevel) { sideEffectName = _.text.FromString("AcediaCore's `BroadcastHandler` injected"); diff --git a/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastAPI.uc b/sources/KFRealm/Server/Unreal/BroadcastsAPI/KF1_BroadcastAPI.uc similarity index 98% rename from sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastAPI.uc rename to sources/KFRealm/Server/Unreal/BroadcastsAPI/KF1_BroadcastAPI.uc index b13c28c..0dd5feb 100644 --- a/sources/KFRealm/Server/Unreal/BroadcastsAPI/BroadcastAPI.uc +++ b/sources/KFRealm/Server/Unreal/BroadcastsAPI/KF1_BroadcastAPI.uc @@ -1,5 +1,5 @@ /** - * Acedia's default implementation for `BroadcastAPIBase`. + * Acedia's default implementation for `BroadcastAPI`. * Copyright 2021-2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class BroadcastAPI extends BroadcastAPIBase; +class KF1_BroadcastAPI extends BroadcastAPI; // Tracks if we have already tried to add our own `BroadcastHandler` to avoid // wasting resources/spamming errors in the log about our inability to do so diff --git a/sources/KFRealm/Server/Unreal/GameRulesAPI/GameRulesAPI.uc b/sources/KFRealm/Server/Unreal/GameRulesAPI/KF1_GameRulesAPI.uc similarity index 98% rename from sources/KFRealm/Server/Unreal/GameRulesAPI/GameRulesAPI.uc rename to sources/KFRealm/Server/Unreal/GameRulesAPI/KF1_GameRulesAPI.uc index 243e8b3..89cbf67 100644 --- a/sources/KFRealm/Server/Unreal/GameRulesAPI/GameRulesAPI.uc +++ b/sources/KFRealm/Server/Unreal/GameRulesAPI/KF1_GameRulesAPI.uc @@ -1,5 +1,5 @@ /** - * Acedia's default implementation for `GameRulesAPIBase` API. + * Acedia's default implementation for `GameRulesAPI` API. * Copyright 2021-2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class GameRulesAPI extends GameRulesAPIBase; +class KF1_GameRulesAPI extends GameRulesAPI; // Tracks if we have already tried to add our own `BroadcastHandler` to avoid // wasting resources/spamming errors in the log about our inability to do so diff --git a/sources/KFRealm/Server/Unreal/InventoryAPI/InventoryAPI.uc b/sources/KFRealm/Server/Unreal/InventoryAPI/KF1_InventoryAPI.uc similarity index 98% rename from sources/KFRealm/Server/Unreal/InventoryAPI/InventoryAPI.uc rename to sources/KFRealm/Server/Unreal/InventoryAPI/KF1_InventoryAPI.uc index 3e50481..fda62bf 100644 --- a/sources/KFRealm/Server/Unreal/InventoryAPI/InventoryAPI.uc +++ b/sources/KFRealm/Server/Unreal/InventoryAPI/KF1_InventoryAPI.uc @@ -1,5 +1,5 @@ /** - * Acedia's default implementation for `InventoryAPIBase`. + * Acedia's default implementation for `InventoryAPI`. * Copyright 2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class InventoryAPI extends InventoryAPIBase +class KF1_InventoryAPI extends InventoryAPI config(AcediaSystem); public function array GetDualiesPairs() diff --git a/sources/KFRealm/Server/Unreal/ServerUnrealAPI.uc b/sources/KFRealm/Server/Unreal/KF1_ServerUnrealAPI.uc similarity index 96% rename from sources/KFRealm/Server/Unreal/ServerUnrealAPI.uc rename to sources/KFRealm/Server/Unreal/KF1_ServerUnrealAPI.uc index f7bf8d0..5fcc201 100644 --- a/sources/KFRealm/Server/Unreal/ServerUnrealAPI.uc +++ b/sources/KFRealm/Server/Unreal/KF1_ServerUnrealAPI.uc @@ -1,5 +1,5 @@ /** - * Acedia's default implementation for `ServerUnrealAPIBase`. + * Acedia's default implementation for `ServerUnrealAPI`. * Copyright 2021-2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class ServerUnrealAPI extends ServerUnrealAPIBase; +class KF1_ServerUnrealAPI extends ServerUnrealAPI; var private LoggerAPI.Definition fatalNoStalker; diff --git a/sources/KFRealm/Server/Unreal/MutatorAPI/MutatorAPI.uc b/sources/KFRealm/Server/Unreal/MutatorAPI/KF1_MutatorAPI.uc similarity index 95% rename from sources/KFRealm/Server/Unreal/MutatorAPI/MutatorAPI.uc rename to sources/KFRealm/Server/Unreal/MutatorAPI/KF1_MutatorAPI.uc index d0645b7..43c5da1 100644 --- a/sources/KFRealm/Server/Unreal/MutatorAPI/MutatorAPI.uc +++ b/sources/KFRealm/Server/Unreal/MutatorAPI/KF1_MutatorAPI.uc @@ -1,5 +1,5 @@ /** - * Acedia's default implementation for `MutatorAPIBase` API. + * Acedia's default implementation for `MutatorAPI` API. * Copyright 2021 - 2022 Anton Tarasenko *------------------------------------------------------------------------------ * This file is part of Acedia. @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class MutatorAPI extends MutatorAPIBase; +class KF1_MutatorAPI extends MutatorAPI; /* SIGNAL */ public function Mutator_OnCheckReplacement_Slot OnCheckReplacement( diff --git a/sources/ServerRealm/API/Time/ServerTimeAPIBase.uc b/sources/ServerRealm/API/Time/ServerTimeAPI.uc similarity index 98% rename from sources/ServerRealm/API/Time/ServerTimeAPIBase.uc rename to sources/ServerRealm/API/Time/ServerTimeAPI.uc index 1f33bd0..b863d3f 100644 --- a/sources/ServerRealm/API/Time/ServerTimeAPIBase.uc +++ b/sources/ServerRealm/API/Time/ServerTimeAPI.uc @@ -17,7 +17,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class ServerTimeAPIBase extends AcediaObject +class ServerTimeAPI extends AcediaObject abstract; /** diff --git a/sources/ServerRealm/API/Unreal/BroadcastsAPI/BroadcastAPIBase.uc b/sources/ServerRealm/API/Unreal/BroadcastsAPI/BroadcastAPI.uc similarity index 99% rename from sources/ServerRealm/API/Unreal/BroadcastsAPI/BroadcastAPIBase.uc rename to sources/ServerRealm/API/Unreal/BroadcastsAPI/BroadcastAPI.uc index e5dabd8..2e04480 100644 --- a/sources/ServerRealm/API/Unreal/BroadcastsAPI/BroadcastAPIBase.uc +++ b/sources/ServerRealm/API/Unreal/BroadcastsAPI/BroadcastAPI.uc @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class BroadcastAPIBase extends AcediaObject +class BroadcastAPI extends AcediaObject abstract; /** diff --git a/sources/ServerRealm/API/Unreal/GameRulesAPI/GameRulesAPIBase.uc b/sources/ServerRealm/API/Unreal/GameRulesAPI/GameRulesAPI.uc similarity index 99% rename from sources/ServerRealm/API/Unreal/GameRulesAPI/GameRulesAPIBase.uc rename to sources/ServerRealm/API/Unreal/GameRulesAPI/GameRulesAPI.uc index a2c0893..87b4729 100644 --- a/sources/ServerRealm/API/Unreal/GameRulesAPI/GameRulesAPIBase.uc +++ b/sources/ServerRealm/API/Unreal/GameRulesAPI/GameRulesAPI.uc @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class GameRulesAPIBase extends AcediaObject +class GameRulesAPI extends AcediaObject abstract; /** diff --git a/sources/ServerRealm/API/Unreal/InventoryAPI/InventoryAPIBase.uc b/sources/ServerRealm/API/Unreal/InventoryAPI/InventoryAPI.uc similarity index 99% rename from sources/ServerRealm/API/Unreal/InventoryAPI/InventoryAPIBase.uc rename to sources/ServerRealm/API/Unreal/InventoryAPI/InventoryAPI.uc index f84ed9a..9d60cd1 100644 --- a/sources/ServerRealm/API/Unreal/InventoryAPI/InventoryAPIBase.uc +++ b/sources/ServerRealm/API/Unreal/InventoryAPI/InventoryAPI.uc @@ -19,7 +19,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class InventoryAPIBase extends AcediaObject +class InventoryAPI extends AcediaObject config(AcediaSystem) abstract; diff --git a/sources/ServerRealm/API/Unreal/MutatorsAPI/MutatorAPIBase.uc b/sources/ServerRealm/API/Unreal/MutatorsAPI/MutatorAPI.uc similarity index 98% rename from sources/ServerRealm/API/Unreal/MutatorsAPI/MutatorAPIBase.uc rename to sources/ServerRealm/API/Unreal/MutatorsAPI/MutatorAPI.uc index 9487dd1..02303a4 100644 --- a/sources/ServerRealm/API/Unreal/MutatorsAPI/MutatorAPIBase.uc +++ b/sources/ServerRealm/API/Unreal/MutatorsAPI/MutatorAPI.uc @@ -18,7 +18,7 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class MutatorAPIBase extends AcediaObject +class MutatorAPI extends AcediaObject abstract; /** diff --git a/sources/ServerRealm/API/Unreal/ServerUnrealAPIBase.uc b/sources/ServerRealm/API/Unreal/ServerUnrealAPI.uc similarity index 76% rename from sources/ServerRealm/API/Unreal/ServerUnrealAPIBase.uc rename to sources/ServerRealm/API/Unreal/ServerUnrealAPI.uc index 01bec57..bf8e219 100644 --- a/sources/ServerRealm/API/Unreal/ServerUnrealAPIBase.uc +++ b/sources/ServerRealm/API/Unreal/ServerUnrealAPI.uc @@ -18,15 +18,15 @@ * You should have received a copy of the GNU General Public License * along with Acedia. If not, see . */ -class ServerUnrealAPIBase extends UnrealAPIBase +class ServerUnrealAPI extends UnrealAPI abstract; var protected bool initialized; -var public MutatorAPIBase mutator; -var public GameRulesAPIBase gameRules; -var public BroadcastAPIBase broadcasts; -var public InventoryAPIBase inventory; +var public MutatorAPI mutator; +var public GameRulesAPI gameRules; +var public BroadcastAPI broadcasts; +var public InventoryAPI inventory; public function Initialize(class adapterClass) { @@ -37,13 +37,13 @@ public function Initialize(class adapterClass) if (adapterClass == none) { return; } - mutator = MutatorAPIBase(_.memory.Allocate( + mutator = MutatorAPI(_.memory.Allocate( adapterClass.default.serverMutatorAPIClass)); - gameRules = GameRulesAPIBase(_.memory.Allocate( + gameRules = GameRulesAPI(_.memory.Allocate( adapterClass.default.serverGameRulesAPIClass)); - broadcasts = BroadcastAPIBase(_.memory.Allocate( + broadcasts = BroadcastAPI(_.memory.Allocate( adapterClass.default.serverBroadcastAPIClass)); - inventory = InventoryAPIBase(_.memory.Allocate( + inventory = InventoryAPI (_.memory.Allocate( adapterClass.default.serverInventoryAPIClass)); } diff --git a/sources/ServerRealm/ServerAcediaAdapter.uc b/sources/ServerRealm/ServerAcediaAdapter.uc index 681a67f..dff3223 100644 --- a/sources/ServerRealm/ServerAcediaAdapter.uc +++ b/sources/ServerRealm/ServerAcediaAdapter.uc @@ -22,19 +22,19 @@ class ServerAcediaAdapter extends AcediaAdapter abstract; -var public const class serverTimeAPIClass; -var public const class serverUnrealAPIClass; -var public const class serverBroadcastAPIClass; -var public const class serverGameRulesAPIClass; -var public const class serverInventoryAPIClass; -var public const class serverMutatorAPIClass; +var public const class serverTimeAPIClass; +var public const class serverUnrealAPIClass; +var public const class serverBroadcastAPIClass; +var public const class serverGameRulesAPIClass; +var public const class serverInventoryAPIClass; +var public const class serverMutatorAPIClass; defaultproperties { - serverTimeAPIClass = class'ServerTimeAPI' - serverUnrealAPIClass = class'ServerUnrealAPI' - serverBroadcastAPIClass = class'BroadcastAPI' - serverGameRulesAPIClass = class'GameRulesAPI' - serverInventoryAPIClass = class'InventoryAPI' - serverMutatorAPIClass = class'MutatorAPI' + serverTimeAPIClass = class'KF1_ServerTimeAPI' + serverUnrealAPIClass = class'KF1_ServerUnrealAPI' + serverBroadcastAPIClass = class'KF1_BroadcastAPI' + serverGameRulesAPIClass = class'KF1_GameRulesAPI' + serverInventoryAPIClass = class'KF1_InventoryAPI' + serverMutatorAPIClass = class'KF1_MutatorAPI' } \ No newline at end of file diff --git a/sources/ServerRealm/ServerGlobal.uc b/sources/ServerRealm/ServerGlobal.uc index 2c8dad4..a217f84 100644 --- a/sources/ServerRealm/ServerGlobal.uc +++ b/sources/ServerRealm/ServerGlobal.uc @@ -25,9 +25,9 @@ class ServerGlobal extends CoreGlobal; // main instance in this variable's default value. var protected ServerGlobal myself; -var public KFFrontend kf; -var public ServerUnrealAPIBase unreal; -var public ServerTimeAPIBase time; +var public KFFrontend kf; +var public ServerUnrealAPI unreal; +var public ServerTimeAPI time; var private LoggerAPI.Definition fatBadAdapterClass; @@ -64,7 +64,7 @@ protected function Initialize() return; } _ = class'Global'.static.GetInstance(); - unreal = ServerUnrealAPIBase( + unreal = ServerUnrealAPI( _.memory.Allocate(serverAdapterClass.default.serverUnrealAPIClass)); unreal.Initialize(serverAdapterClass); time = ServerTimeAPI(