aboutsummaryrefslogtreecommitdiff
path: root/engines/sword25/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'engines/sword25/kernel')
-rw-r--r--engines/sword25/kernel/kernel.cpp18
-rw-r--r--engines/sword25/kernel/kernel.h16
-rw-r--r--engines/sword25/kernel/kernel_script.cpp12
-rw-r--r--engines/sword25/kernel/persistenceservice.cpp4
-rw-r--r--engines/sword25/kernel/resmanager.cpp2
-rw-r--r--engines/sword25/kernel/resource.cpp2
-rw-r--r--engines/sword25/kernel/service_ids.h24
7 files changed, 39 insertions, 39 deletions
diff --git a/engines/sword25/kernel/kernel.cpp b/engines/sword25/kernel/kernel.cpp
index 4e61965c93..40833fed04 100644
--- a/engines/sword25/kernel/kernel.cpp
+++ b/engines/sword25/kernel/kernel.cpp
@@ -85,7 +85,7 @@ BS_Kernel::BS_Kernel() :
_pResourceManager = new BS_ResourceManager(this);
// Initialise the script engine
- BS_ScriptEngine *pScript = static_cast<BS_ScriptEngine *>(NewService("script", "lua"));
+ ScriptEngine *pScript = static_cast<ScriptEngine *>(NewService("script", "lua"));
if (!pScript || !pScript->Init()) {
_InitSuccess = false;
return;
@@ -405,8 +405,8 @@ GraphicEngine *BS_Kernel::GetGfx() {
/**
* Returns a pointer to the active Sfx Service, or NULL if no Sfx service is active
*/
-BS_SoundEngine *BS_Kernel::GetSfx() {
- return static_cast<BS_SoundEngine *>(GetService("sfx"));
+SoundEngine *BS_Kernel::GetSfx() {
+ return static_cast<SoundEngine *>(GetService("sfx"));
}
// -----------------------------------------------------------------------------
@@ -414,8 +414,8 @@ BS_SoundEngine *BS_Kernel::GetSfx() {
/**
* Returns a pointer to the active input service, or NULL if no input service is active
*/
-BS_InputEngine *BS_Kernel::GetInput() {
- return static_cast<BS_InputEngine *>(GetService("input"));
+InputEngine *BS_Kernel::GetInput() {
+ return static_cast<InputEngine *>(GetService("input"));
}
// -----------------------------------------------------------------------------
@@ -423,8 +423,8 @@ BS_InputEngine *BS_Kernel::GetInput() {
/**
* Returns a pointer to the active package manager, or NULL if no manager is active
*/
-BS_PackageManager *BS_Kernel::GetPackage() {
- return static_cast<BS_PackageManager *>(GetService("package"));
+PackageManager *BS_Kernel::GetPackage() {
+ return static_cast<PackageManager *>(GetService("package"));
}
// -----------------------------------------------------------------------------
@@ -432,8 +432,8 @@ BS_PackageManager *BS_Kernel::GetPackage() {
/**
* Returns a pointer to the script engine, or NULL if it is not active
*/
-BS_ScriptEngine *BS_Kernel::GetScript() {
- return static_cast<BS_ScriptEngine *>(GetService("script"));
+ScriptEngine *BS_Kernel::GetScript() {
+ return static_cast<ScriptEngine *>(GetService("script"));
}
// -----------------------------------------------------------------------------
diff --git a/engines/sword25/kernel/kernel.h b/engines/sword25/kernel/kernel.h
index 1ccf03b879..e7861db32b 100644
--- a/engines/sword25/kernel/kernel.h
+++ b/engines/sword25/kernel/kernel.h
@@ -62,10 +62,10 @@ namespace Sword25 {
// Class definitions
class BS_Service;
class GraphicEngine;
-class BS_ScriptEngine;
-class BS_SoundEngine;
-class BS_InputEngine;
-class BS_PackageManager;
+class ScriptEngine;
+class SoundEngine;
+class InputEngine;
+class PackageManager;
class MoviePlayer;
/**
@@ -194,19 +194,19 @@ public:
/**
* Returns a pointer to the active Sfx Service, or NULL if no Sfx service is active
*/
- BS_SoundEngine *GetSfx();
+ SoundEngine *GetSfx();
/**
* Returns a pointer to the active input service, or NULL if no input service is active
*/
- BS_InputEngine *GetInput();
+ InputEngine *GetInput();
/**
* Returns a pointer to the active package manager, or NULL if no manager is active
*/
- BS_PackageManager *GetPackage();
+ PackageManager *GetPackage();
/**
* Returns a pointer to the script engine, or NULL if it is not active
*/
- BS_ScriptEngine *GetScript();
+ ScriptEngine *GetScript();
/**
* Returns a pointer to the movie player, or NULL if it is not active
*/
diff --git a/engines/sword25/kernel/kernel_script.cpp b/engines/sword25/kernel/kernel_script.cpp
index 9d62694ad3..9ae78d1e95 100644
--- a/engines/sword25/kernel/kernel_script.cpp
+++ b/engines/sword25/kernel/kernel_script.cpp
@@ -171,7 +171,7 @@ static int Crash(lua_State *L) {
static int ExecuteFile(lua_State *L) {
BS_Kernel *pKernel = BS_Kernel::GetInstance();
BS_ASSERT(pKernel);
- BS_ScriptEngine *pSE = static_cast<BS_ScriptEngine *>(pKernel->GetService("script"));
+ ScriptEngine *pSE = static_cast<ScriptEngine *>(pKernel->GetService("script"));
BS_ASSERT(pSE);
lua_pushbooleancpp(L, pSE->ExecuteFile(luaL_checkstring(L, 1)));
@@ -723,15 +723,15 @@ static const luaL_reg PERSISTENCE_FUNCTIONS[] = {
// -----------------------------------------------------------------------------
bool BS_Kernel::_RegisterScriptBindings() {
- BS_ScriptEngine *pScript = static_cast<BS_ScriptEngine *>(GetService("script"));
+ ScriptEngine *pScript = static_cast<ScriptEngine *>(GetService("script"));
BS_ASSERT(pScript);
lua_State *L = static_cast<lua_State *>(pScript->GetScriptObject());
BS_ASSERT(L);
- if (!BS_LuaBindhelper::AddFunctionsToLib(L, KERNEL_LIBRARY_NAME, KERNEL_FUNCTIONS)) return false;
- if (!BS_LuaBindhelper::AddFunctionsToLib(L, WINDOW_LIBRARY_NAME, WINDOW_FUNCTIONS)) return false;
- if (!BS_LuaBindhelper::AddFunctionsToLib(L, RESOURCE_LIBRARY_NAME, RESOURCE_FUNCTIONS)) return false;
- if (!BS_LuaBindhelper::AddFunctionsToLib(L, PERSISTENCE_LIBRARY_NAME, PERSISTENCE_FUNCTIONS)) return false;
+ if (!LuaBindhelper::AddFunctionsToLib(L, KERNEL_LIBRARY_NAME, KERNEL_FUNCTIONS)) return false;
+ if (!LuaBindhelper::AddFunctionsToLib(L, WINDOW_LIBRARY_NAME, WINDOW_FUNCTIONS)) return false;
+ if (!LuaBindhelper::AddFunctionsToLib(L, RESOURCE_LIBRARY_NAME, RESOURCE_FUNCTIONS)) return false;
+ if (!LuaBindhelper::AddFunctionsToLib(L, PERSISTENCE_LIBRARY_NAME, PERSISTENCE_FUNCTIONS)) return false;
return true;
}
diff --git a/engines/sword25/kernel/persistenceservice.cpp b/engines/sword25/kernel/persistenceservice.cpp
index aeadc2fe9d..dda570b1d2 100644
--- a/engines/sword25/kernel/persistenceservice.cpp
+++ b/engines/sword25/kernel/persistenceservice.cpp
@@ -321,7 +321,7 @@ bool BS_PersistenceService::SaveGame(unsigned int SlotID, const Common::String &
BS_OutputPersistenceBlock Writer;
bool Success = true;
Success &= BS_Kernel::GetInstance()->GetScript()->Persist(Writer);
- Success &= BS_RegionRegistry::GetInstance().Persist(Writer);
+ Success &= RegionRegistry::GetInstance().Persist(Writer);
Success &= BS_Kernel::GetInstance()->GetGfx()->Persist(Writer);
Success &= BS_Kernel::GetInstance()->GetSfx()->Persist(Writer);
Success &= BS_Kernel::GetInstance()->GetInput()->Persist(Writer);
@@ -437,7 +437,7 @@ bool BS_PersistenceService::LoadGame(unsigned int SlotID) {
bool Success = true;
Success &= BS_Kernel::GetInstance()->GetScript()->Unpersist(Reader);
// Muss unbedingt nach Script passieren. Da sonst die bereits wiederhergestellten Regions per Garbage-Collection gekillt werden.
- Success &= BS_RegionRegistry::GetInstance().Unpersist(Reader);
+ Success &= RegionRegistry::GetInstance().Unpersist(Reader);
Success &= BS_Kernel::GetInstance()->GetGfx()->Unpersist(Reader);
Success &= BS_Kernel::GetInstance()->GetSfx()->Unpersist(Reader);
Success &= BS_Kernel::GetInstance()->GetInput()->Unpersist(Reader);
diff --git a/engines/sword25/kernel/resmanager.cpp b/engines/sword25/kernel/resmanager.cpp
index dd7a38b753..1f9fb69230 100644
--- a/engines/sword25/kernel/resmanager.cpp
+++ b/engines/sword25/kernel/resmanager.cpp
@@ -256,7 +256,7 @@ BS_Resource *BS_ResourceManager::LoadResource(const Common::String &FileName) {
*/
Common::String BS_ResourceManager::GetUniqueFileName(const Common::String &FileName) const {
// Get a pointer to the package manager
- BS_PackageManager *pPackage = (BS_PackageManager *)m_KernelPtr->GetService("package");
+ PackageManager *pPackage = (PackageManager *)m_KernelPtr->GetService("package");
if (!pPackage) {
BS_LOG_ERRORLN("Could not get package manager.");
return Common::String("");
diff --git a/engines/sword25/kernel/resource.cpp b/engines/sword25/kernel/resource.cpp
index c33bfea268..2223d1b965 100644
--- a/engines/sword25/kernel/resource.cpp
+++ b/engines/sword25/kernel/resource.cpp
@@ -46,7 +46,7 @@ BS_Resource::BS_Resource(const Common::String &FileName, RESOURCE_TYPES Type) :
_RefCount(0) {
BS_ASSERT(BS_Kernel::GetInstance()->GetService("package"));
- _FileName = static_cast<BS_PackageManager *>(BS_Kernel::GetInstance()->GetService("package"))->GetAbsolutePath(FileName);
+ _FileName = static_cast<PackageManager *>(BS_Kernel::GetInstance()->GetService("package"))->GetAbsolutePath(FileName);
_FileNameHash = BS_String::GetHash(FileName);
}
diff --git a/engines/sword25/kernel/service_ids.h b/engines/sword25/kernel/service_ids.h
index 895579a559..1135317cb2 100644
--- a/engines/sword25/kernel/service_ids.h
+++ b/engines/sword25/kernel/service_ids.h
@@ -49,13 +49,13 @@
namespace Sword25 {
-BS_Service *BS_OpenGLGfx_CreateObject(BS_Kernel *pKernel);
-BS_Service *BS_ScummVMPackageManager_CreateObject(BS_Kernel *pKernel);
+BS_Service *OpenGLGfx_CreateObject(BS_Kernel *pKernel);
+BS_Service *ScummVMPackageManager_CreateObject(BS_Kernel *pKernel);
BS_Service *ScummVMInput_CreateObject(BS_Kernel *pKernel);
-BS_Service *BS_FMODExSound_CreateObject(BS_Kernel *pKernel);
-BS_Service *BS_LuaScriptEngine_CreateObject(BS_Kernel *pKernel);
-BS_Service *BS_Geometry_CreateObject(BS_Kernel *pKernel);
-BS_Service *BS_OggTheora_CreateObject(BS_Kernel *pKernel);
+BS_Service *FMODExSound_CreateObject(BS_Kernel *pKernel);
+BS_Service *LuaScriptEngine_CreateObject(BS_Kernel *pKernel);
+BS_Service *Geometry_CreateObject(BS_Kernel *pKernel);
+BS_Service *OggTheora_CreateObject(BS_Kernel *pKernel);
// Services are recorded in this table
const BS_ServiceInfo BS_SERVICE_TABLE[] = {
@@ -64,13 +64,13 @@ const BS_ServiceInfo BS_SERVICE_TABLE[] = {
// of the class and returns it
// Example:
// BS_ServiceInfo("Superclass", "Service", CreateMethod)
- BS_ServiceInfo("gfx", "opengl", BS_OpenGLGfx_CreateObject),
- BS_ServiceInfo("package", "archiveFS", BS_ScummVMPackageManager_CreateObject),
+ BS_ServiceInfo("gfx", "opengl", OpenGLGfx_CreateObject),
+ BS_ServiceInfo("package", "archiveFS", ScummVMPackageManager_CreateObject),
BS_ServiceInfo("input", "winapi", ScummVMInput_CreateObject),
- BS_ServiceInfo("sfx", "fmodex", BS_FMODExSound_CreateObject),
- BS_ServiceInfo("script", "lua", BS_LuaScriptEngine_CreateObject),
- BS_ServiceInfo("geometry", "std", BS_Geometry_CreateObject),
- BS_ServiceInfo("fmv", "oggtheora", BS_OggTheora_CreateObject),
+ BS_ServiceInfo("sfx", "fmodex", FMODExSound_CreateObject),
+ BS_ServiceInfo("script", "lua", LuaScriptEngine_CreateObject),
+ BS_ServiceInfo("geometry", "std", Geometry_CreateObject),
+ BS_ServiceInfo("fmv", "oggtheora", OggTheora_CreateObject),
};
const unsigned int BS_SERVICE_COUNT = sizeof(BS_SERVICE_TABLE) / sizeof(BS_ServiceInfo);