diff --git a/.gitignore b/.gitignore
index bbb3dcd..16b17fc 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1 @@
-/SteamworksSDK/*
+/SteamworksSDK/*
diff --git a/BlitzSteam.cpp b/BlitzSteam.cpp
index 8bd1048..e3e4236 100644
--- a/BlitzSteam.cpp
+++ b/BlitzSteam.cpp
@@ -1,33 +1,33 @@
-// BlitzSteam - Steam wrapper for Blitz
-// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU Lesser General Public License as
-// published by the Free Software Foundation, either version 3 of the
-// License, or (at your option) any later version.
-//
-// This program 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 Lesser General Public License
-// along with this program. If not, see .
-
-#include "BlitzSteam.h"
-
-#include
-uint32_t WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) {
- switch (fdwReason) {
- case DLL_PROCESS_ATTACH:
- break;
- case DLL_PROCESS_DETACH:
- break;
- case DLL_THREAD_ATTACH:
- break;
- case DLL_THREAD_DETACH:
- break;
- }
-
- return true;
+// BlitzSteam - Steam wrapper for Blitz
+// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as
+// published by the Free Software Foundation, either version 3 of the
+// License, or (at your option) any later version.
+//
+// This program 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 Lesser General Public License
+// along with this program. If not, see .
+
+#include "BlitzSteam.h"
+
+#include
+uint32_t WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved) {
+ switch (fdwReason) {
+ case DLL_PROCESS_ATTACH:
+ break;
+ case DLL_PROCESS_DETACH:
+ break;
+ case DLL_THREAD_ATTACH:
+ break;
+ case DLL_THREAD_DETACH:
+ break;
+ }
+
+ return true;
}
\ No newline at end of file
diff --git a/BlitzSteam.h b/BlitzSteam.h
index 9d23f43..372d7ac 100644
--- a/BlitzSteam.h
+++ b/BlitzSteam.h
@@ -1,26 +1,26 @@
-// BlitzSteam - Steam wrapper for Blitz
-// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU Lesser General Public License as
-// published by the Free Software Foundation, either version 3 of the
-// License, or (at your option) any later version.
-//
-// This program 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 Lesser General Public License
-// along with this program. If not, see .
-
-#pragma once
-#include "BlitzSteamInternal.h"
-
-// Our Stuff
-#include "Helpers/BlitzPointer.h"
-#include "Types/BlitzCallback.h"
-#include "Types/CSteamID.h"
-#include "Types/Double.h"
-#include "Types/Long.h"
-#include "Types/Memory.h"
+// BlitzSteam - Steam wrapper for Blitz
+// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as
+// published by the Free Software Foundation, either version 3 of the
+// License, or (at your option) any later version.
+//
+// This program 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 Lesser General Public License
+// along with this program. If not, see .
+
+#pragma once
+#include "BlitzSteamInternal.h"
+
+// Our Stuff
+#include "Helpers/BlitzPointer.h"
+#include "Types/BlitzCallback.h"
+#include "Types/CSteamID.h"
+#include "Types/Double.h"
+#include "Types/Long.h"
+#include "Types/Memory.h"
diff --git a/BlitzSteam.vcxproj b/BlitzSteam.vcxproj
index f58ee5f..e5ed5a4 100644
--- a/BlitzSteam.vcxproj
+++ b/BlitzSteam.vcxproj
@@ -59,7 +59,7 @@
MultiThreaded
false
$(ProjectDir);%(AdditionalIncludeDirectories)
- ProgramDatabase
+ EditAndContinue
false
EnableFastChecks
4Bytes
@@ -156,12 +156,15 @@
+
+
+
@@ -195,15 +198,17 @@
+
+
-
+
@@ -221,6 +226,7 @@
+
diff --git a/BlitzSteam.vcxproj.filters b/BlitzSteam.vcxproj.filters
index fd88909..473a802 100644
--- a/BlitzSteam.vcxproj.filters
+++ b/BlitzSteam.vcxproj.filters
@@ -128,6 +128,15 @@
Source Files\Types
+
+ Source Files\Types
+
+
+ Source Files\Types
+
+
+ Source Files\Helpers
+
@@ -157,6 +166,12 @@
Header Files
+
+ Header Files\Types
+
+
+ Header Files\Types
+
@@ -200,9 +215,6 @@
Resource Files\Decls
-
- Resource Files\Decls
-
Resource Files\Decls
@@ -293,6 +305,12 @@
Resource Files
+
+ Resource Files\Decls
+
+
+ Resource Files\Decls
+
diff --git a/BlitzSteam.vcxproj.user b/BlitzSteam.vcxproj.user
index ef5ff2a..2a22e69 100644
--- a/BlitzSteam.vcxproj.user
+++ b/BlitzSteam.vcxproj.user
@@ -1,4 +1,4 @@
-
-
-
+
+
+
\ No newline at end of file
diff --git a/BlitzSteamInternal.h b/BlitzSteamInternal.h
index 9b2196a..06b3a55 100644
--- a/BlitzSteamInternal.h
+++ b/BlitzSteamInternal.h
@@ -1,31 +1,31 @@
-// BlitzSteam - Steam wrapper for Blitz
-// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU Lesser General Public License as
-// published by the Free Software Foundation, either version 3 of the
-// License, or (at your option) any later version.
-//
-// This program 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 Lesser General Public License
-// along with this program. If not, see .
-
-#pragma once
-
-// Macros
-//#define DLL_FUNCTION(type) extern "C" type __stdcall
-#define DLL(type) extern "C" __declspec(dllexport) type __stdcall
-
-// C/C++ Includes
-#include
-#include
-#include
-#include
-
-// Steam
-#include "SteamworksSDK/public/steam/steam_api.h"
+// BlitzSteam - Steam wrapper for Blitz
+// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as
+// published by the Free Software Foundation, either version 3 of the
+// License, or (at your option) any later version.
+//
+// This program 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 Lesser General Public License
+// along with this program. If not, see .
+
+#pragma once
+
+// Macros
+//#define DLL_FUNCTION(type) extern "C" type __stdcall
+#define DLL(type) extern "C" __declspec(dllexport) type __stdcall
+
+// C/C++ Includes
+#include
+#include
+#include
+#include
+
+// Steam
+#include "SteamworksSDK/public/steam/steam_api.h"
#include "SteamworksSDK/public/steam/steam_gameserver.h"
\ No newline at end of file
diff --git a/Helpers/BlitzPointer.cpp b/Helpers/BlitzPointer.cpp
new file mode 100644
index 0000000..31f523b
--- /dev/null
+++ b/Helpers/BlitzPointer.cpp
@@ -0,0 +1,52 @@
+// BlitzSteam - Steam wrapper for Blitz
+// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as
+// published by the Free Software Foundation, either version 3 of the
+// License, or (at your option) any later version.
+//
+// This program 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 Lesser General Public License
+// along with this program. If not, see .
+
+#include "BlitzPointer.h"
+
+DLL(intptr_t) BS_BlitzPointer_GetReturnAddress() {
+ intptr_t BasePointer, ReturnAddress;
+
+ __asm { //ASM. Do touch if suicidal.
+ mov BasePointer, ebp; // Store current BasePointer
+ }
+
+ // Blitz uses X86 Call-Near (E8) instructions to call its own functions.
+ // We can simply deduce the Return Address like this because of that.
+ //-- Parent_EBP = *EBP
+ //-- Parent_RP = Parent_EBP + 16
+ ReturnAddress = *(intptr_t*)((*(intptr_t*)BasePointer) + 16);
+
+ return ReturnAddress;
+}
+
+DLL(intptr_t) BS_BlitzPointer_GetFunctionPointer() {
+ intptr_t BasePointer, ReturnAddress, FunctionPointer;
+
+ __asm { //ASM. Do touch if suicidal.
+ mov BasePointer, ebp; // Store current BasePointer
+ }
+
+ // Blitz uses X86 Call-Near (E8) instructions to call its own functions.
+ // We can simply deduce the Return Address like this because of that.
+ //-- Parent_EBP = *EBP
+ //-- Parent_RP = Parent_EBP + 16
+ ReturnAddress = *(intptr_t*)((*(intptr_t*)BasePointer) + 16);
+
+ // And since it's a Call-Near, the call is offset to the return address.
+ FunctionPointer = ReturnAddress + *(intptr_t*)(ReturnAddress - 4);
+
+ return FunctionPointer;
+}
diff --git a/Helpers/BlitzPointer.h b/Helpers/BlitzPointer.h
index 1618ddc..83d9928 100644
--- a/Helpers/BlitzPointer.h
+++ b/Helpers/BlitzPointer.h
@@ -1,32 +1,36 @@
-// BlitzSteam - Steam wrapper for Blitz
-// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU Lesser General Public License as
-// published by the Free Software Foundation, either version 3 of the
-// License, or (at your option) any later version.
-//
-// This program 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 Lesser General Public License
-// along with this program. If not, see .
-
-#pragma once
-
-// Types of Blitz Functions.
-typedef int32_t(__stdcall *BP_BlitzFunction0_t)();
-typedef int32_t(__stdcall *BP_BlitzFunction1_t)(int32_t);
-typedef int32_t(__stdcall *BP_BlitzFunction2_t)(int32_t, int32_t);
-typedef int32_t(__stdcall *BP_BlitzFunction3_t)(int32_t, int32_t, int32_t);
-typedef int32_t(__stdcall *BP_BlitzFunction4_t)(int32_t, int32_t, int32_t, int32_t);
-typedef int32_t(__stdcall *BP_BlitzFunction5_t)(int32_t, int32_t, int32_t, int32_t, int32_t);
-
-#define BP_CallFunction0(ptr) (reinterpret_cast(ptr))()
-#define BP_CallFunction1(ptr, p1) (reinterpret_cast(ptr))(p1)
-#define BP_CallFunction2(ptr, p1, p2) (reinterpret_cast(ptr))(p1, p2)
-#define BP_CallFunction3(ptr, p1, p2, p3) (reinterpret_cast(ptr))(p1, p2, p3)
-#define BP_CallFunction4(ptr, p1, p2, p3, p4) (reinterpret_cast(ptr))(p1, p2, p3, p4)
-#define BP_CallFunction5(ptr, p1, p2, p3, p4, p5) (reinterpret_cast(ptr))(p1, p2, p3, p4, p5)
\ No newline at end of file
+// BlitzSteam - Steam wrapper for Blitz
+// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as
+// published by the Free Software Foundation, either version 3 of the
+// License, or (at your option) any later version.
+//
+// This program 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 Lesser General Public License
+// along with this program. If not, see .
+
+#pragma once
+#include "BlitzSteamInternal.h"
+
+DLL(intptr_t) BS_BlitzPointer_GetReturnAddress();
+DLL(intptr_t) BS_BlitzPointer_GetFunctionPointer();
+
+// Types of Blitz Functions.
+typedef int32_t(__stdcall *BP_BlitzFunction0_t)();
+typedef int32_t(__stdcall *BP_BlitzFunction1_t)(int32_t);
+typedef int32_t(__stdcall *BP_BlitzFunction2_t)(int32_t, int32_t);
+typedef int32_t(__stdcall *BP_BlitzFunction3_t)(int32_t, int32_t, int32_t);
+typedef int32_t(__stdcall *BP_BlitzFunction4_t)(int32_t, int32_t, int32_t, int32_t);
+typedef int32_t(__stdcall *BP_BlitzFunction5_t)(int32_t, int32_t, int32_t, int32_t, int32_t);
+
+#define BP_CallFunction0(ptr) (ptr)()
+#define BP_CallFunction1(ptr, p1) (ptr)(p1)
+#define BP_CallFunction2(ptr, p1, p2) (ptr)(p1, p2)
+#define BP_CallFunction3(ptr, p1, p2, p3) (ptr)(p1, p2, p3)
+#define BP_CallFunction4(ptr, p1, p2, p3, p4) (ptr)(p1, p2, p3, p4)
+#define BP_CallFunction5(ptr, p1, p2, p3, p4, p5) (ptr)(p1, p2, p3, p4, p5)
\ No newline at end of file
diff --git a/Helpers/Helper.cpp b/Helpers/Helper.cpp
index ff8e691..5a8b45c 100644
--- a/Helpers/Helper.cpp
+++ b/Helpers/Helper.cpp
@@ -1,90 +1,60 @@
-// BlitzSteam - Steam wrapper for Blitz
-// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU Lesser General Public License as
-// published by the Free Software Foundation, either version 3 of the
-// License, or (at your option) any later version.
-//
-// This program 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 Lesser General Public License
-// along with this program. If not, see .
-
-#include "Helper.h"
-
-DLL(const char*) BS_Helper_FormatUnixTime(uint32_t unTime, const char* pchFormat) {
- char* output = new char[strlen(pchFormat) * 4];
- time_t t = unTime;
- struct tm *tm = localtime(&t);
- strftime(output, sizeof(output), pchFormat, tm);
- delete tm;
- return output;
-}
-
-DLL(void) BS_Helper_CopyMemoryIntMangle(void* pSource, void* pDest, int32_t iMangling,
- uint32_t iSourceW, uint32_t iSourceH, uint32_t iDestW, uint32_t iDestH,
- uint32_t iAreaX, uint32_t iAreaY, uint32_t iAreaW, uint32_t iAreaH) {
- int8_t iMangleByte0 = static_cast((iMangling & 0xFF));
- int8_t iMangleByte1 = static_cast((iMangling & 0xFF00) >> 8);
- int8_t iMangleByte2 = static_cast((iMangling & 0xFF0000) >> 16);
- int8_t iMangleByte3 = static_cast((iMangling & 0xFF000000) >> 24);
-
- if (pSource > pDest) {
- // Start at beginning
- for (uint32_t iY = iAreaY; iY < (iAreaY + iAreaH); iY++) {
- // Only do this once per loop
- for (uint32_t iX = iAreaX; iX < (iAreaX + iAreaW); iX++) {
- // Could technically optimize the following into single instructions, but this is fast enough for now.
- uint32_t* pSourceOff = reinterpret_cast(pSource) + ((iSourceW * iY) + iX);
- uint32_t* pDestOff = reinterpret_cast(pDest) + ((iDestW * iY) + iX);
-
- // Allow Mangling using just a single integer and checking on the fly if it's positive or negative to branch out to the correct shift.
- *pDestOff =
- (iMangleByte0 > 0 ?
- (*pSourceOff & 0xFF) >> iMangleByte0 :
- (*pSourceOff & 0xFF) << -iMangleByte0)
- + (iMangleByte1 > 0 ?
- (*pSourceOff & 0xFF00) >> iMangleByte1 :
- (*pSourceOff & 0xFF00) << -iMangleByte1)
- + (iMangleByte2 > 0 ?
- (*pSourceOff & 0xFF0000) >> iMangleByte2 :
- (*pSourceOff & 0xFF0000) << -iMangleByte2)
- + (iMangleByte3 > 0 ?
- (*pSourceOff & 0xFF000000) >> iMangleByte3 :
- (*pSourceOff & 0xFF000000) << -iMangleByte3);
- }
- }
- } else {
- //ToDo, mirror the above. Instead of adding we subtract.
- //// Start at end
-
- //for (uint32_t iY = y + h; iY >= y; iY--) {
- // pSourceOff = reinterpret_cast(pSource) + ((tw * iY) + x);
- // pDestOff = reinterpret_cast(pDest) + ((tw * iY) + x);
-
- // for (uint32_t iX = x + w; iX >= x; iX--) {
- // *pDestOff =
- // (iMangleByte0 > 0 ?
- // (*pSourceOff & 0xFF) >> iMangleByte0 :
- // (*pSourceOff & 0xFF) << -iMangleByte0)
- // + (iMangleByte1 > 0 ?
- // (*pSourceOff & 0xFF00) >> iMangleByte1 :
- // (*pSourceOff & 0xFF00) << -iMangleByte1)
- // + (iMangleByte2 > 0 ?
- // (*pSourceOff & 0xFF0000) >> iMangleByte2 :
- // (*pSourceOff & 0xFF0000) << -iMangleByte2)
- // + (iMangleByte3 > 0 ?
- // (*pSourceOff & 0xFF000000) >> iMangleByte3 :
- // (*pSourceOff & 0xFF000000) << -iMangleByte3);
-
- // // Above is some mangling magic i learned in some source code. Allows you to define a byte bit shift using a single integer.
- // pSourceOff -= 1;
- // pDestOff -= 1;
- // }
- //}
- }
+// BlitzSteam - Steam wrapper for Blitz
+// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as
+// published by the Free Software Foundation, either version 3 of the
+// License, or (at your option) any later version.
+//
+// This program 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 Lesser General Public License
+// along with this program. If not, see .
+
+#include "Helper.h"
+
+DLL(const char*) BS_Helper_FormatUnixTime(uint32_t unTime, const char* pchFormat) {
+ char* output = new char[strlen(pchFormat) * 4];
+ time_t t = unTime;
+ struct tm *tm = localtime(&t);
+ strftime(output, sizeof(output), pchFormat, tm);
+ delete tm;
+ return output;
+}
+
+DLL(void) BS_Helper_CopyMemoryIntMangle(void* pSource, void* pDest, int32_t iMangling,
+ uint32_t iSourceW, uint32_t iSourceH, uint32_t iDestW, uint32_t iDestH,
+ uint32_t iAreaX, uint32_t iAreaY, uint32_t iAreaW, uint32_t iAreaH) {
+ int8_t iMangleByte0 = static_cast((iMangling & 0xFF));
+ int8_t iMangleByte1 = static_cast((iMangling & 0xFF00) >> 8);
+ int8_t iMangleByte2 = static_cast((iMangling & 0xFF0000) >> 16);
+ int8_t iMangleByte3 = static_cast((iMangling & 0xFF000000) >> 24);
+
+ // Start at beginning
+ for (uint32_t iY = iAreaY; iY < (iAreaY + iAreaH); iY++) {
+ // Only do this once per loop
+ for (uint32_t iX = iAreaX; iX < (iAreaX + iAreaW); iX++) {
+ // Could technically optimize the following into single instructions, but this is fast enough for now.
+ uint32_t* pSourceOff = reinterpret_cast(pSource) + ((iSourceW * iY) + iX);
+ uint32_t* pDestOff = reinterpret_cast(pDest) + ((iDestW * iY) + iX);
+
+ // Allow Mangling using just a single integer and checking on the fly if it's positive or negative to branch out to the correct shift.
+ *pDestOff =
+ (iMangleByte0 > 0 ?
+ (*pSourceOff & 0xFF) >> iMangleByte0 :
+ (*pSourceOff & 0xFF) << -iMangleByte0)
+ + (iMangleByte1 > 0 ?
+ (*pSourceOff & 0xFF00) >> iMangleByte1 :
+ (*pSourceOff & 0xFF00) << -iMangleByte1)
+ + (iMangleByte2 > 0 ?
+ (*pSourceOff & 0xFF0000) >> iMangleByte2 :
+ (*pSourceOff & 0xFF0000) << -iMangleByte2)
+ + (iMangleByte3 > 0 ?
+ (*pSourceOff & 0xFF000000) >> iMangleByte3 :
+ (*pSourceOff & 0xFF000000) << -iMangleByte3);
+ }
+ }
}
\ No newline at end of file
diff --git a/Helpers/Helper.h b/Helpers/Helper.h
index 64e617b..d712fcd 100644
--- a/Helpers/Helper.h
+++ b/Helpers/Helper.h
@@ -1,21 +1,21 @@
-// BlitzSteam - Steam wrapper for Blitz
-// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU Lesser General Public License as
-// published by the Free Software Foundation, either version 3 of the
-// License, or (at your option) any later version.
-//
-// This program 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 Lesser General Public License
-// along with this program. If not, see .
-
-#pragma once
-#include "BlitzSteam.h"
-#include
-
+// BlitzSteam - Steam wrapper for Blitz
+// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as
+// published by the Free Software Foundation, either version 3 of the
+// License, or (at your option) any later version.
+//
+// This program 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 Lesser General Public License
+// along with this program. If not, see .
+
+#pragma once
+#include "BlitzSteam.h"
+#include
+
DLL(const char*) BS_Helper_FormatUnixTime(uint32_t unTime, const char* pchFormat);
\ No newline at end of file
diff --git a/Resources/BlitzSteam.LICENSE b/Resources/BlitzSteam.LICENSE
index 9cecc1d..c65825e 100644
--- a/Resources/BlitzSteam.LICENSE
+++ b/Resources/BlitzSteam.LICENSE
@@ -1,674 +1,674 @@
- GNU GENERAL PUBLIC LICENSE
- Version 3, 29 June 2007
-
- Copyright (C) 2007 Free Software Foundation, Inc.
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
- Preamble
-
- The GNU General Public License is a free, copyleft license for
-software and other kinds of works.
-
- The licenses for most software and other practical works are designed
-to take away your freedom to share and change the works. By contrast,
-the GNU General Public License is intended to guarantee your freedom to
-share and change all versions of a program--to make sure it remains free
-software for all its users. We, the Free Software Foundation, use the
-GNU General Public License for most of our software; it applies also to
-any other work released this way by its authors. You can apply it to
-your programs, too.
-
- When we speak of free software, we are referring to freedom, not
-price. Our General Public Licenses are designed to make sure that you
-have the freedom to distribute copies of free software (and charge for
-them if you wish), that you receive source code or can get it if you
-want it, that you can change the software or use pieces of it in new
-free programs, and that you know you can do these things.
-
- To protect your rights, we need to prevent others from denying you
-these rights or asking you to surrender the rights. Therefore, you have
-certain responsibilities if you distribute copies of the software, or if
-you modify it: responsibilities to respect the freedom of others.
-
- For example, if you distribute copies of such a program, whether
-gratis or for a fee, you must pass on to the recipients the same
-freedoms that you received. You must make sure that they, too, receive
-or can get the source code. And you must show them these terms so they
-know their rights.
-
- Developers that use the GNU GPL protect your rights with two steps:
-(1) assert copyright on the software, and (2) offer you this License
-giving you legal permission to copy, distribute and/or modify it.
-
- For the developers' and authors' protection, the GPL clearly explains
-that there is no warranty for this free software. For both users' and
-authors' sake, the GPL requires that modified versions be marked as
-changed, so that their problems will not be attributed erroneously to
-authors of previous versions.
-
- Some devices are designed to deny users access to install or run
-modified versions of the software inside them, although the manufacturer
-can do so. This is fundamentally incompatible with the aim of
-protecting users' freedom to change the software. The systematic
-pattern of such abuse occurs in the area of products for individuals to
-use, which is precisely where it is most unacceptable. Therefore, we
-have designed this version of the GPL to prohibit the practice for those
-products. If such problems arise substantially in other domains, we
-stand ready to extend this provision to those domains in future versions
-of the GPL, as needed to protect the freedom of users.
-
- Finally, every program is threatened constantly by software patents.
-States should not allow patents to restrict development and use of
-software on general-purpose computers, but in those that do, we wish to
-avoid the special danger that patents applied to a free program could
-make it effectively proprietary. To prevent this, the GPL assures that
-patents cannot be used to render the program non-free.
-
- The precise terms and conditions for copying, distribution and
-modification follow.
-
- TERMS AND CONDITIONS
-
- 0. Definitions.
-
- "This License" refers to version 3 of the GNU General Public License.
-
- "Copyright" also means copyright-like laws that apply to other kinds of
-works, such as semiconductor masks.
-
- "The Program" refers to any copyrightable work licensed under this
-License. Each licensee is addressed as "you". "Licensees" and
-"recipients" may be individuals or organizations.
-
- To "modify" a work means to copy from or adapt all or part of the work
-in a fashion requiring copyright permission, other than the making of an
-exact copy. The resulting work is called a "modified version" of the
-earlier work or a work "based on" the earlier work.
-
- A "covered work" means either the unmodified Program or a work based
-on the Program.
-
- To "propagate" a work means to do anything with it that, without
-permission, would make you directly or secondarily liable for
-infringement under applicable copyright law, except executing it on a
-computer or modifying a private copy. Propagation includes copying,
-distribution (with or without modification), making available to the
-public, and in some countries other activities as well.
-
- To "convey" a work means any kind of propagation that enables other
-parties to make or receive copies. Mere interaction with a user through
-a computer network, with no transfer of a copy, is not conveying.
-
- An interactive user interface displays "Appropriate Legal Notices"
-to the extent that it includes a convenient and prominently visible
-feature that (1) displays an appropriate copyright notice, and (2)
-tells the user that there is no warranty for the work (except to the
-extent that warranties are provided), that licensees may convey the
-work under this License, and how to view a copy of this License. If
-the interface presents a list of user commands or options, such as a
-menu, a prominent item in the list meets this criterion.
-
- 1. Source Code.
-
- The "source code" for a work means the preferred form of the work
-for making modifications to it. "Object code" means any non-source
-form of a work.
-
- A "Standard Interface" means an interface that either is an official
-standard defined by a recognized standards body, or, in the case of
-interfaces specified for a particular programming language, one that
-is widely used among developers working in that language.
-
- The "System Libraries" of an executable work include anything, other
-than the work as a whole, that (a) is included in the normal form of
-packaging a Major Component, but which is not part of that Major
-Component, and (b) serves only to enable use of the work with that
-Major Component, or to implement a Standard Interface for which an
-implementation is available to the public in source code form. A
-"Major Component", in this context, means a major essential component
-(kernel, window system, and so on) of the specific operating system
-(if any) on which the executable work runs, or a compiler used to
-produce the work, or an object code interpreter used to run it.
-
- The "Corresponding Source" for a work in object code form means all
-the source code needed to generate, install, and (for an executable
-work) run the object code and to modify the work, including scripts to
-control those activities. However, it does not include the work's
-System Libraries, or general-purpose tools or generally available free
-programs which are used unmodified in performing those activities but
-which are not part of the work. For example, Corresponding Source
-includes interface definition files associated with source files for
-the work, and the source code for shared libraries and dynamically
-linked subprograms that the work is specifically designed to require,
-such as by intimate data communication or control flow between those
-subprograms and other parts of the work.
-
- The Corresponding Source need not include anything that users
-can regenerate automatically from other parts of the Corresponding
-Source.
-
- The Corresponding Source for a work in source code form is that
-same work.
-
- 2. Basic Permissions.
-
- All rights granted under this License are granted for the term of
-copyright on the Program, and are irrevocable provided the stated
-conditions are met. This License explicitly affirms your unlimited
-permission to run the unmodified Program. The output from running a
-covered work is covered by this License only if the output, given its
-content, constitutes a covered work. This License acknowledges your
-rights of fair use or other equivalent, as provided by copyright law.
-
- You may make, run and propagate covered works that you do not
-convey, without conditions so long as your license otherwise remains
-in force. You may convey covered works to others for the sole purpose
-of having them make modifications exclusively for you, or provide you
-with facilities for running those works, provided that you comply with
-the terms of this License in conveying all material for which you do
-not control copyright. Those thus making or running the covered works
-for you must do so exclusively on your behalf, under your direction
-and control, on terms that prohibit them from making any copies of
-your copyrighted material outside their relationship with you.
-
- Conveying under any other circumstances is permitted solely under
-the conditions stated below. Sublicensing is not allowed; section 10
-makes it unnecessary.
-
- 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
-
- No covered work shall be deemed part of an effective technological
-measure under any applicable law fulfilling obligations under article
-11 of the WIPO copyright treaty adopted on 20 December 1996, or
-similar laws prohibiting or restricting circumvention of such
-measures.
-
- When you convey a covered work, you waive any legal power to forbid
-circumvention of technological measures to the extent such circumvention
-is effected by exercising rights under this License with respect to
-the covered work, and you disclaim any intention to limit operation or
-modification of the work as a means of enforcing, against the work's
-users, your or third parties' legal rights to forbid circumvention of
-technological measures.
-
- 4. Conveying Verbatim Copies.
-
- You may convey verbatim copies of the Program's source code as you
-receive it, in any medium, provided that you conspicuously and
-appropriately publish on each copy an appropriate copyright notice;
-keep intact all notices stating that this License and any
-non-permissive terms added in accord with section 7 apply to the code;
-keep intact all notices of the absence of any warranty; and give all
-recipients a copy of this License along with the Program.
-
- You may charge any price or no price for each copy that you convey,
-and you may offer support or warranty protection for a fee.
-
- 5. Conveying Modified Source Versions.
-
- You may convey a work based on the Program, or the modifications to
-produce it from the Program, in the form of source code under the
-terms of section 4, provided that you also meet all of these conditions:
-
- a) The work must carry prominent notices stating that you modified
- it, and giving a relevant date.
-
- b) The work must carry prominent notices stating that it is
- released under this License and any conditions added under section
- 7. This requirement modifies the requirement in section 4 to
- "keep intact all notices".
-
- c) You must license the entire work, as a whole, under this
- License to anyone who comes into possession of a copy. This
- License will therefore apply, along with any applicable section 7
- additional terms, to the whole of the work, and all its parts,
- regardless of how they are packaged. This License gives no
- permission to license the work in any other way, but it does not
- invalidate such permission if you have separately received it.
-
- d) If the work has interactive user interfaces, each must display
- Appropriate Legal Notices; however, if the Program has interactive
- interfaces that do not display Appropriate Legal Notices, your
- work need not make them do so.
-
- A compilation of a covered work with other separate and independent
-works, which are not by their nature extensions of the covered work,
-and which are not combined with it such as to form a larger program,
-in or on a volume of a storage or distribution medium, is called an
-"aggregate" if the compilation and its resulting copyright are not
-used to limit the access or legal rights of the compilation's users
-beyond what the individual works permit. Inclusion of a covered work
-in an aggregate does not cause this License to apply to the other
-parts of the aggregate.
-
- 6. Conveying Non-Source Forms.
-
- You may convey a covered work in object code form under the terms
-of sections 4 and 5, provided that you also convey the
-machine-readable Corresponding Source under the terms of this License,
-in one of these ways:
-
- a) Convey the object code in, or embodied in, a physical product
- (including a physical distribution medium), accompanied by the
- Corresponding Source fixed on a durable physical medium
- customarily used for software interchange.
-
- b) Convey the object code in, or embodied in, a physical product
- (including a physical distribution medium), accompanied by a
- written offer, valid for at least three years and valid for as
- long as you offer spare parts or customer support for that product
- model, to give anyone who possesses the object code either (1) a
- copy of the Corresponding Source for all the software in the
- product that is covered by this License, on a durable physical
- medium customarily used for software interchange, for a price no
- more than your reasonable cost of physically performing this
- conveying of source, or (2) access to copy the
- Corresponding Source from a network server at no charge.
-
- c) Convey individual copies of the object code with a copy of the
- written offer to provide the Corresponding Source. This
- alternative is allowed only occasionally and noncommercially, and
- only if you received the object code with such an offer, in accord
- with subsection 6b.
-
- d) Convey the object code by offering access from a designated
- place (gratis or for a charge), and offer equivalent access to the
- Corresponding Source in the same way through the same place at no
- further charge. You need not require recipients to copy the
- Corresponding Source along with the object code. If the place to
- copy the object code is a network server, the Corresponding Source
- may be on a different server (operated by you or a third party)
- that supports equivalent copying facilities, provided you maintain
- clear directions next to the object code saying where to find the
- Corresponding Source. Regardless of what server hosts the
- Corresponding Source, you remain obligated to ensure that it is
- available for as long as needed to satisfy these requirements.
-
- e) Convey the object code using peer-to-peer transmission, provided
- you inform other peers where the object code and Corresponding
- Source of the work are being offered to the general public at no
- charge under subsection 6d.
-
- A separable portion of the object code, whose source code is excluded
-from the Corresponding Source as a System Library, need not be
-included in conveying the object code work.
-
- A "User Product" is either (1) a "consumer product", which means any
-tangible personal property which is normally used for personal, family,
-or household purposes, or (2) anything designed or sold for incorporation
-into a dwelling. In determining whether a product is a consumer product,
-doubtful cases shall be resolved in favor of coverage. For a particular
-product received by a particular user, "normally used" refers to a
-typical or common use of that class of product, regardless of the status
-of the particular user or of the way in which the particular user
-actually uses, or expects or is expected to use, the product. A product
-is a consumer product regardless of whether the product has substantial
-commercial, industrial or non-consumer uses, unless such uses represent
-the only significant mode of use of the product.
-
- "Installation Information" for a User Product means any methods,
-procedures, authorization keys, or other information required to install
-and execute modified versions of a covered work in that User Product from
-a modified version of its Corresponding Source. The information must
-suffice to ensure that the continued functioning of the modified object
-code is in no case prevented or interfered with solely because
-modification has been made.
-
- If you convey an object code work under this section in, or with, or
-specifically for use in, a User Product, and the conveying occurs as
-part of a transaction in which the right of possession and use of the
-User Product is transferred to the recipient in perpetuity or for a
-fixed term (regardless of how the transaction is characterized), the
-Corresponding Source conveyed under this section must be accompanied
-by the Installation Information. But this requirement does not apply
-if neither you nor any third party retains the ability to install
-modified object code on the User Product (for example, the work has
-been installed in ROM).
-
- The requirement to provide Installation Information does not include a
-requirement to continue to provide support service, warranty, or updates
-for a work that has been modified or installed by the recipient, or for
-the User Product in which it has been modified or installed. Access to a
-network may be denied when the modification itself materially and
-adversely affects the operation of the network or violates the rules and
-protocols for communication across the network.
-
- Corresponding Source conveyed, and Installation Information provided,
-in accord with this section must be in a format that is publicly
-documented (and with an implementation available to the public in
-source code form), and must require no special password or key for
-unpacking, reading or copying.
-
- 7. Additional Terms.
-
- "Additional permissions" are terms that supplement the terms of this
-License by making exceptions from one or more of its conditions.
-Additional permissions that are applicable to the entire Program shall
-be treated as though they were included in this License, to the extent
-that they are valid under applicable law. If additional permissions
-apply only to part of the Program, that part may be used separately
-under those permissions, but the entire Program remains governed by
-this License without regard to the additional permissions.
-
- When you convey a copy of a covered work, you may at your option
-remove any additional permissions from that copy, or from any part of
-it. (Additional permissions may be written to require their own
-removal in certain cases when you modify the work.) You may place
-additional permissions on material, added by you to a covered work,
-for which you have or can give appropriate copyright permission.
-
- Notwithstanding any other provision of this License, for material you
-add to a covered work, you may (if authorized by the copyright holders of
-that material) supplement the terms of this License with terms:
-
- a) Disclaiming warranty or limiting liability differently from the
- terms of sections 15 and 16 of this License; or
-
- b) Requiring preservation of specified reasonable legal notices or
- author attributions in that material or in the Appropriate Legal
- Notices displayed by works containing it; or
-
- c) Prohibiting misrepresentation of the origin of that material, or
- requiring that modified versions of such material be marked in
- reasonable ways as different from the original version; or
-
- d) Limiting the use for publicity purposes of names of licensors or
- authors of the material; or
-
- e) Declining to grant rights under trademark law for use of some
- trade names, trademarks, or service marks; or
-
- f) Requiring indemnification of licensors and authors of that
- material by anyone who conveys the material (or modified versions of
- it) with contractual assumptions of liability to the recipient, for
- any liability that these contractual assumptions directly impose on
- those licensors and authors.
-
- All other non-permissive additional terms are considered "further
-restrictions" within the meaning of section 10. If the Program as you
-received it, or any part of it, contains a notice stating that it is
-governed by this License along with a term that is a further
-restriction, you may remove that term. If a license document contains
-a further restriction but permits relicensing or conveying under this
-License, you may add to a covered work material governed by the terms
-of that license document, provided that the further restriction does
-not survive such relicensing or conveying.
-
- If you add terms to a covered work in accord with this section, you
-must place, in the relevant source files, a statement of the
-additional terms that apply to those files, or a notice indicating
-where to find the applicable terms.
-
- Additional terms, permissive or non-permissive, may be stated in the
-form of a separately written license, or stated as exceptions;
-the above requirements apply either way.
-
- 8. Termination.
-
- You may not propagate or modify a covered work except as expressly
-provided under this License. Any attempt otherwise to propagate or
-modify it is void, and will automatically terminate your rights under
-this License (including any patent licenses granted under the third
-paragraph of section 11).
-
- However, if you cease all violation of this License, then your
-license from a particular copyright holder is reinstated (a)
-provisionally, unless and until the copyright holder explicitly and
-finally terminates your license, and (b) permanently, if the copyright
-holder fails to notify you of the violation by some reasonable means
-prior to 60 days after the cessation.
-
- Moreover, your license from a particular copyright holder is
-reinstated permanently if the copyright holder notifies you of the
-violation by some reasonable means, this is the first time you have
-received notice of violation of this License (for any work) from that
-copyright holder, and you cure the violation prior to 30 days after
-your receipt of the notice.
-
- Termination of your rights under this section does not terminate the
-licenses of parties who have received copies or rights from you under
-this License. If your rights have been terminated and not permanently
-reinstated, you do not qualify to receive new licenses for the same
-material under section 10.
-
- 9. Acceptance Not Required for Having Copies.
-
- You are not required to accept this License in order to receive or
-run a copy of the Program. Ancillary propagation of a covered work
-occurring solely as a consequence of using peer-to-peer transmission
-to receive a copy likewise does not require acceptance. However,
-nothing other than this License grants you permission to propagate or
-modify any covered work. These actions infringe copyright if you do
-not accept this License. Therefore, by modifying or propagating a
-covered work, you indicate your acceptance of this License to do so.
-
- 10. Automatic Licensing of Downstream Recipients.
-
- Each time you convey a covered work, the recipient automatically
-receives a license from the original licensors, to run, modify and
-propagate that work, subject to this License. You are not responsible
-for enforcing compliance by third parties with this License.
-
- An "entity transaction" is a transaction transferring control of an
-organization, or substantially all assets of one, or subdividing an
-organization, or merging organizations. If propagation of a covered
-work results from an entity transaction, each party to that
-transaction who receives a copy of the work also receives whatever
-licenses to the work the party's predecessor in interest had or could
-give under the previous paragraph, plus a right to possession of the
-Corresponding Source of the work from the predecessor in interest, if
-the predecessor has it or can get it with reasonable efforts.
-
- You may not impose any further restrictions on the exercise of the
-rights granted or affirmed under this License. For example, you may
-not impose a license fee, royalty, or other charge for exercise of
-rights granted under this License, and you may not initiate litigation
-(including a cross-claim or counterclaim in a lawsuit) alleging that
-any patent claim is infringed by making, using, selling, offering for
-sale, or importing the Program or any portion of it.
-
- 11. Patents.
-
- A "contributor" is a copyright holder who authorizes use under this
-License of the Program or a work on which the Program is based. The
-work thus licensed is called the contributor's "contributor version".
-
- A contributor's "essential patent claims" are all patent claims
-owned or controlled by the contributor, whether already acquired or
-hereafter acquired, that would be infringed by some manner, permitted
-by this License, of making, using, or selling its contributor version,
-but do not include claims that would be infringed only as a
-consequence of further modification of the contributor version. For
-purposes of this definition, "control" includes the right to grant
-patent sublicenses in a manner consistent with the requirements of
-this License.
-
- Each contributor grants you a non-exclusive, worldwide, royalty-free
-patent license under the contributor's essential patent claims, to
-make, use, sell, offer for sale, import and otherwise run, modify and
-propagate the contents of its contributor version.
-
- In the following three paragraphs, a "patent license" is any express
-agreement or commitment, however denominated, not to enforce a patent
-(such as an express permission to practice a patent or covenant not to
-sue for patent infringement). To "grant" such a patent license to a
-party means to make such an agreement or commitment not to enforce a
-patent against the party.
-
- If you convey a covered work, knowingly relying on a patent license,
-and the Corresponding Source of the work is not available for anyone
-to copy, free of charge and under the terms of this License, through a
-publicly available network server or other readily accessible means,
-then you must either (1) cause the Corresponding Source to be so
-available, or (2) arrange to deprive yourself of the benefit of the
-patent license for this particular work, or (3) arrange, in a manner
-consistent with the requirements of this License, to extend the patent
-license to downstream recipients. "Knowingly relying" means you have
-actual knowledge that, but for the patent license, your conveying the
-covered work in a country, or your recipient's use of the covered work
-in a country, would infringe one or more identifiable patents in that
-country that you have reason to believe are valid.
-
- If, pursuant to or in connection with a single transaction or
-arrangement, you convey, or propagate by procuring conveyance of, a
-covered work, and grant a patent license to some of the parties
-receiving the covered work authorizing them to use, propagate, modify
-or convey a specific copy of the covered work, then the patent license
-you grant is automatically extended to all recipients of the covered
-work and works based on it.
-
- A patent license is "discriminatory" if it does not include within
-the scope of its coverage, prohibits the exercise of, or is
-conditioned on the non-exercise of one or more of the rights that are
-specifically granted under this License. You may not convey a covered
-work if you are a party to an arrangement with a third party that is
-in the business of distributing software, under which you make payment
-to the third party based on the extent of your activity of conveying
-the work, and under which the third party grants, to any of the
-parties who would receive the covered work from you, a discriminatory
-patent license (a) in connection with copies of the covered work
-conveyed by you (or copies made from those copies), or (b) primarily
-for and in connection with specific products or compilations that
-contain the covered work, unless you entered into that arrangement,
-or that patent license was granted, prior to 28 March 2007.
-
- Nothing in this License shall be construed as excluding or limiting
-any implied license or other defenses to infringement that may
-otherwise be available to you under applicable patent law.
-
- 12. No Surrender of Others' Freedom.
-
- If conditions are imposed on you (whether by court order, agreement or
-otherwise) that contradict the conditions of this License, they do not
-excuse you from the conditions of this License. If you cannot convey a
-covered work so as to satisfy simultaneously your obligations under this
-License and any other pertinent obligations, then as a consequence you may
-not convey it at all. For example, if you agree to terms that obligate you
-to collect a royalty for further conveying from those to whom you convey
-the Program, the only way you could satisfy both those terms and this
-License would be to refrain entirely from conveying the Program.
-
- 13. Use with the GNU Affero General Public License.
-
- Notwithstanding any other provision of this License, you have
-permission to link or combine any covered work with a work licensed
-under version 3 of the GNU Affero General Public License into a single
-combined work, and to convey the resulting work. The terms of this
-License will continue to apply to the part which is the covered work,
-but the special requirements of the GNU Affero General Public License,
-section 13, concerning interaction through a network will apply to the
-combination as such.
-
- 14. Revised Versions of this License.
-
- The Free Software Foundation may publish revised and/or new versions of
-the GNU General Public License from time to time. Such new versions will
-be similar in spirit to the present version, but may differ in detail to
-address new problems or concerns.
-
- Each version is given a distinguishing version number. If the
-Program specifies that a certain numbered version of the GNU General
-Public License "or any later version" applies to it, you have the
-option of following the terms and conditions either of that numbered
-version or of any later version published by the Free Software
-Foundation. If the Program does not specify a version number of the
-GNU General Public License, you may choose any version ever published
-by the Free Software Foundation.
-
- If the Program specifies that a proxy can decide which future
-versions of the GNU General Public License can be used, that proxy's
-public statement of acceptance of a version permanently authorizes you
-to choose that version for the Program.
-
- Later license versions may give you additional or different
-permissions. However, no additional obligations are imposed on any
-author or copyright holder as a result of your choosing to follow a
-later version.
-
- 15. Disclaimer of Warranty.
-
- THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
-APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
-HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
-OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
-THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
-PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
-IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
-ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
-
- 16. Limitation of Liability.
-
- IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
-WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
-THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
-GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
-USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
-DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
-PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
-EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
-SUCH DAMAGES.
-
- 17. Interpretation of Sections 15 and 16.
-
- If the disclaimer of warranty and limitation of liability provided
-above cannot be given local legal effect according to their terms,
-reviewing courts shall apply local law that most closely approximates
-an absolute waiver of all civil liability in connection with the
-Program, unless a warranty or assumption of liability accompanies a
-copy of the Program in return for a fee.
-
- END OF TERMS AND CONDITIONS
-
- How to Apply These Terms to Your New Programs
-
- If you develop a new program, and you want it to be of the greatest
-possible use to the public, the best way to achieve this is to make it
-free software which everyone can redistribute and change under these terms.
-
- To do so, attach the following notices to the program. It is safest
-to attach them to the start of each source file to most effectively
-state the exclusion of warranty; and each file should have at least
-the "copyright" line and a pointer to where the full notice is found.
-
- {one line to give the program's name and a brief idea of what it does.}
- Copyright (C) {year} {name of author}
-
- This program 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, either version 3 of the License, or
- (at your option) any later version.
-
- This program 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 this program. If not, see .
-
-Also add information on how to contact you by electronic and paper mail.
-
- If the program does terminal interaction, make it output a short
-notice like this when it starts in an interactive mode:
-
- {project} Copyright (C) {year} {fullname}
- This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
- This is free software, and you are welcome to redistribute it
- under certain conditions; type `show c' for details.
-
-The hypothetical commands `show w' and `show c' should show the appropriate
-parts of the General Public License. Of course, your program's commands
-might be different; for a GUI interface, you would use an "about box".
-
- You should also get your employer (if you work as a programmer) or school,
-if any, to sign a "copyright disclaimer" for the program, if necessary.
-For more information on this, and how to apply and follow the GNU GPL, see
-.
-
- The GNU General Public License does not permit incorporating your program
-into proprietary programs. If your program is a subroutine library, you
-may consider it more useful to permit linking proprietary applications with
-the library. If this is what you want to do, use the GNU Lesser General
-Public License instead of this License. But first, please read
-.
+ GNU GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The GNU General Public License is a free, copyleft license for
+software and other kinds of works.
+
+ The licenses for most software and other practical works are designed
+to take away your freedom to share and change the works. By contrast,
+the GNU General Public License is intended to guarantee your freedom to
+share and change all versions of a program--to make sure it remains free
+software for all its users. We, the Free Software Foundation, use the
+GNU General Public License for most of our software; it applies also to
+any other work released this way by its authors. You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+them if you wish), that you receive source code or can get it if you
+want it, that you can change the software or use pieces of it in new
+free programs, and that you know you can do these things.
+
+ To protect your rights, we need to prevent others from denying you
+these rights or asking you to surrender the rights. Therefore, you have
+certain responsibilities if you distribute copies of the software, or if
+you modify it: responsibilities to respect the freedom of others.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must pass on to the recipients the same
+freedoms that you received. You must make sure that they, too, receive
+or can get the source code. And you must show them these terms so they
+know their rights.
+
+ Developers that use the GNU GPL protect your rights with two steps:
+(1) assert copyright on the software, and (2) offer you this License
+giving you legal permission to copy, distribute and/or modify it.
+
+ For the developers' and authors' protection, the GPL clearly explains
+that there is no warranty for this free software. For both users' and
+authors' sake, the GPL requires that modified versions be marked as
+changed, so that their problems will not be attributed erroneously to
+authors of previous versions.
+
+ Some devices are designed to deny users access to install or run
+modified versions of the software inside them, although the manufacturer
+can do so. This is fundamentally incompatible with the aim of
+protecting users' freedom to change the software. The systematic
+pattern of such abuse occurs in the area of products for individuals to
+use, which is precisely where it is most unacceptable. Therefore, we
+have designed this version of the GPL to prohibit the practice for those
+products. If such problems arise substantially in other domains, we
+stand ready to extend this provision to those domains in future versions
+of the GPL, as needed to protect the freedom of users.
+
+ Finally, every program is threatened constantly by software patents.
+States should not allow patents to restrict development and use of
+software on general-purpose computers, but in those that do, we wish to
+avoid the special danger that patents applied to a free program could
+make it effectively proprietary. To prevent this, the GPL assures that
+patents cannot be used to render the program non-free.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ TERMS AND CONDITIONS
+
+ 0. Definitions.
+
+ "This License" refers to version 3 of the GNU General Public License.
+
+ "Copyright" also means copyright-like laws that apply to other kinds of
+works, such as semiconductor masks.
+
+ "The Program" refers to any copyrightable work licensed under this
+License. Each licensee is addressed as "you". "Licensees" and
+"recipients" may be individuals or organizations.
+
+ To "modify" a work means to copy from or adapt all or part of the work
+in a fashion requiring copyright permission, other than the making of an
+exact copy. The resulting work is called a "modified version" of the
+earlier work or a work "based on" the earlier work.
+
+ A "covered work" means either the unmodified Program or a work based
+on the Program.
+
+ To "propagate" a work means to do anything with it that, without
+permission, would make you directly or secondarily liable for
+infringement under applicable copyright law, except executing it on a
+computer or modifying a private copy. Propagation includes copying,
+distribution (with or without modification), making available to the
+public, and in some countries other activities as well.
+
+ To "convey" a work means any kind of propagation that enables other
+parties to make or receive copies. Mere interaction with a user through
+a computer network, with no transfer of a copy, is not conveying.
+
+ An interactive user interface displays "Appropriate Legal Notices"
+to the extent that it includes a convenient and prominently visible
+feature that (1) displays an appropriate copyright notice, and (2)
+tells the user that there is no warranty for the work (except to the
+extent that warranties are provided), that licensees may convey the
+work under this License, and how to view a copy of this License. If
+the interface presents a list of user commands or options, such as a
+menu, a prominent item in the list meets this criterion.
+
+ 1. Source Code.
+
+ The "source code" for a work means the preferred form of the work
+for making modifications to it. "Object code" means any non-source
+form of a work.
+
+ A "Standard Interface" means an interface that either is an official
+standard defined by a recognized standards body, or, in the case of
+interfaces specified for a particular programming language, one that
+is widely used among developers working in that language.
+
+ The "System Libraries" of an executable work include anything, other
+than the work as a whole, that (a) is included in the normal form of
+packaging a Major Component, but which is not part of that Major
+Component, and (b) serves only to enable use of the work with that
+Major Component, or to implement a Standard Interface for which an
+implementation is available to the public in source code form. A
+"Major Component", in this context, means a major essential component
+(kernel, window system, and so on) of the specific operating system
+(if any) on which the executable work runs, or a compiler used to
+produce the work, or an object code interpreter used to run it.
+
+ The "Corresponding Source" for a work in object code form means all
+the source code needed to generate, install, and (for an executable
+work) run the object code and to modify the work, including scripts to
+control those activities. However, it does not include the work's
+System Libraries, or general-purpose tools or generally available free
+programs which are used unmodified in performing those activities but
+which are not part of the work. For example, Corresponding Source
+includes interface definition files associated with source files for
+the work, and the source code for shared libraries and dynamically
+linked subprograms that the work is specifically designed to require,
+such as by intimate data communication or control flow between those
+subprograms and other parts of the work.
+
+ The Corresponding Source need not include anything that users
+can regenerate automatically from other parts of the Corresponding
+Source.
+
+ The Corresponding Source for a work in source code form is that
+same work.
+
+ 2. Basic Permissions.
+
+ All rights granted under this License are granted for the term of
+copyright on the Program, and are irrevocable provided the stated
+conditions are met. This License explicitly affirms your unlimited
+permission to run the unmodified Program. The output from running a
+covered work is covered by this License only if the output, given its
+content, constitutes a covered work. This License acknowledges your
+rights of fair use or other equivalent, as provided by copyright law.
+
+ You may make, run and propagate covered works that you do not
+convey, without conditions so long as your license otherwise remains
+in force. You may convey covered works to others for the sole purpose
+of having them make modifications exclusively for you, or provide you
+with facilities for running those works, provided that you comply with
+the terms of this License in conveying all material for which you do
+not control copyright. Those thus making or running the covered works
+for you must do so exclusively on your behalf, under your direction
+and control, on terms that prohibit them from making any copies of
+your copyrighted material outside their relationship with you.
+
+ Conveying under any other circumstances is permitted solely under
+the conditions stated below. Sublicensing is not allowed; section 10
+makes it unnecessary.
+
+ 3. Protecting Users' Legal Rights From Anti-Circumvention Law.
+
+ No covered work shall be deemed part of an effective technological
+measure under any applicable law fulfilling obligations under article
+11 of the WIPO copyright treaty adopted on 20 December 1996, or
+similar laws prohibiting or restricting circumvention of such
+measures.
+
+ When you convey a covered work, you waive any legal power to forbid
+circumvention of technological measures to the extent such circumvention
+is effected by exercising rights under this License with respect to
+the covered work, and you disclaim any intention to limit operation or
+modification of the work as a means of enforcing, against the work's
+users, your or third parties' legal rights to forbid circumvention of
+technological measures.
+
+ 4. Conveying Verbatim Copies.
+
+ You may convey verbatim copies of the Program's source code as you
+receive it, in any medium, provided that you conspicuously and
+appropriately publish on each copy an appropriate copyright notice;
+keep intact all notices stating that this License and any
+non-permissive terms added in accord with section 7 apply to the code;
+keep intact all notices of the absence of any warranty; and give all
+recipients a copy of this License along with the Program.
+
+ You may charge any price or no price for each copy that you convey,
+and you may offer support or warranty protection for a fee.
+
+ 5. Conveying Modified Source Versions.
+
+ You may convey a work based on the Program, or the modifications to
+produce it from the Program, in the form of source code under the
+terms of section 4, provided that you also meet all of these conditions:
+
+ a) The work must carry prominent notices stating that you modified
+ it, and giving a relevant date.
+
+ b) The work must carry prominent notices stating that it is
+ released under this License and any conditions added under section
+ 7. This requirement modifies the requirement in section 4 to
+ "keep intact all notices".
+
+ c) You must license the entire work, as a whole, under this
+ License to anyone who comes into possession of a copy. This
+ License will therefore apply, along with any applicable section 7
+ additional terms, to the whole of the work, and all its parts,
+ regardless of how they are packaged. This License gives no
+ permission to license the work in any other way, but it does not
+ invalidate such permission if you have separately received it.
+
+ d) If the work has interactive user interfaces, each must display
+ Appropriate Legal Notices; however, if the Program has interactive
+ interfaces that do not display Appropriate Legal Notices, your
+ work need not make them do so.
+
+ A compilation of a covered work with other separate and independent
+works, which are not by their nature extensions of the covered work,
+and which are not combined with it such as to form a larger program,
+in or on a volume of a storage or distribution medium, is called an
+"aggregate" if the compilation and its resulting copyright are not
+used to limit the access or legal rights of the compilation's users
+beyond what the individual works permit. Inclusion of a covered work
+in an aggregate does not cause this License to apply to the other
+parts of the aggregate.
+
+ 6. Conveying Non-Source Forms.
+
+ You may convey a covered work in object code form under the terms
+of sections 4 and 5, provided that you also convey the
+machine-readable Corresponding Source under the terms of this License,
+in one of these ways:
+
+ a) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by the
+ Corresponding Source fixed on a durable physical medium
+ customarily used for software interchange.
+
+ b) Convey the object code in, or embodied in, a physical product
+ (including a physical distribution medium), accompanied by a
+ written offer, valid for at least three years and valid for as
+ long as you offer spare parts or customer support for that product
+ model, to give anyone who possesses the object code either (1) a
+ copy of the Corresponding Source for all the software in the
+ product that is covered by this License, on a durable physical
+ medium customarily used for software interchange, for a price no
+ more than your reasonable cost of physically performing this
+ conveying of source, or (2) access to copy the
+ Corresponding Source from a network server at no charge.
+
+ c) Convey individual copies of the object code with a copy of the
+ written offer to provide the Corresponding Source. This
+ alternative is allowed only occasionally and noncommercially, and
+ only if you received the object code with such an offer, in accord
+ with subsection 6b.
+
+ d) Convey the object code by offering access from a designated
+ place (gratis or for a charge), and offer equivalent access to the
+ Corresponding Source in the same way through the same place at no
+ further charge. You need not require recipients to copy the
+ Corresponding Source along with the object code. If the place to
+ copy the object code is a network server, the Corresponding Source
+ may be on a different server (operated by you or a third party)
+ that supports equivalent copying facilities, provided you maintain
+ clear directions next to the object code saying where to find the
+ Corresponding Source. Regardless of what server hosts the
+ Corresponding Source, you remain obligated to ensure that it is
+ available for as long as needed to satisfy these requirements.
+
+ e) Convey the object code using peer-to-peer transmission, provided
+ you inform other peers where the object code and Corresponding
+ Source of the work are being offered to the general public at no
+ charge under subsection 6d.
+
+ A separable portion of the object code, whose source code is excluded
+from the Corresponding Source as a System Library, need not be
+included in conveying the object code work.
+
+ A "User Product" is either (1) a "consumer product", which means any
+tangible personal property which is normally used for personal, family,
+or household purposes, or (2) anything designed or sold for incorporation
+into a dwelling. In determining whether a product is a consumer product,
+doubtful cases shall be resolved in favor of coverage. For a particular
+product received by a particular user, "normally used" refers to a
+typical or common use of that class of product, regardless of the status
+of the particular user or of the way in which the particular user
+actually uses, or expects or is expected to use, the product. A product
+is a consumer product regardless of whether the product has substantial
+commercial, industrial or non-consumer uses, unless such uses represent
+the only significant mode of use of the product.
+
+ "Installation Information" for a User Product means any methods,
+procedures, authorization keys, or other information required to install
+and execute modified versions of a covered work in that User Product from
+a modified version of its Corresponding Source. The information must
+suffice to ensure that the continued functioning of the modified object
+code is in no case prevented or interfered with solely because
+modification has been made.
+
+ If you convey an object code work under this section in, or with, or
+specifically for use in, a User Product, and the conveying occurs as
+part of a transaction in which the right of possession and use of the
+User Product is transferred to the recipient in perpetuity or for a
+fixed term (regardless of how the transaction is characterized), the
+Corresponding Source conveyed under this section must be accompanied
+by the Installation Information. But this requirement does not apply
+if neither you nor any third party retains the ability to install
+modified object code on the User Product (for example, the work has
+been installed in ROM).
+
+ The requirement to provide Installation Information does not include a
+requirement to continue to provide support service, warranty, or updates
+for a work that has been modified or installed by the recipient, or for
+the User Product in which it has been modified or installed. Access to a
+network may be denied when the modification itself materially and
+adversely affects the operation of the network or violates the rules and
+protocols for communication across the network.
+
+ Corresponding Source conveyed, and Installation Information provided,
+in accord with this section must be in a format that is publicly
+documented (and with an implementation available to the public in
+source code form), and must require no special password or key for
+unpacking, reading or copying.
+
+ 7. Additional Terms.
+
+ "Additional permissions" are terms that supplement the terms of this
+License by making exceptions from one or more of its conditions.
+Additional permissions that are applicable to the entire Program shall
+be treated as though they were included in this License, to the extent
+that they are valid under applicable law. If additional permissions
+apply only to part of the Program, that part may be used separately
+under those permissions, but the entire Program remains governed by
+this License without regard to the additional permissions.
+
+ When you convey a copy of a covered work, you may at your option
+remove any additional permissions from that copy, or from any part of
+it. (Additional permissions may be written to require their own
+removal in certain cases when you modify the work.) You may place
+additional permissions on material, added by you to a covered work,
+for which you have or can give appropriate copyright permission.
+
+ Notwithstanding any other provision of this License, for material you
+add to a covered work, you may (if authorized by the copyright holders of
+that material) supplement the terms of this License with terms:
+
+ a) Disclaiming warranty or limiting liability differently from the
+ terms of sections 15 and 16 of this License; or
+
+ b) Requiring preservation of specified reasonable legal notices or
+ author attributions in that material or in the Appropriate Legal
+ Notices displayed by works containing it; or
+
+ c) Prohibiting misrepresentation of the origin of that material, or
+ requiring that modified versions of such material be marked in
+ reasonable ways as different from the original version; or
+
+ d) Limiting the use for publicity purposes of names of licensors or
+ authors of the material; or
+
+ e) Declining to grant rights under trademark law for use of some
+ trade names, trademarks, or service marks; or
+
+ f) Requiring indemnification of licensors and authors of that
+ material by anyone who conveys the material (or modified versions of
+ it) with contractual assumptions of liability to the recipient, for
+ any liability that these contractual assumptions directly impose on
+ those licensors and authors.
+
+ All other non-permissive additional terms are considered "further
+restrictions" within the meaning of section 10. If the Program as you
+received it, or any part of it, contains a notice stating that it is
+governed by this License along with a term that is a further
+restriction, you may remove that term. If a license document contains
+a further restriction but permits relicensing or conveying under this
+License, you may add to a covered work material governed by the terms
+of that license document, provided that the further restriction does
+not survive such relicensing or conveying.
+
+ If you add terms to a covered work in accord with this section, you
+must place, in the relevant source files, a statement of the
+additional terms that apply to those files, or a notice indicating
+where to find the applicable terms.
+
+ Additional terms, permissive or non-permissive, may be stated in the
+form of a separately written license, or stated as exceptions;
+the above requirements apply either way.
+
+ 8. Termination.
+
+ You may not propagate or modify a covered work except as expressly
+provided under this License. Any attempt otherwise to propagate or
+modify it is void, and will automatically terminate your rights under
+this License (including any patent licenses granted under the third
+paragraph of section 11).
+
+ However, if you cease all violation of this License, then your
+license from a particular copyright holder is reinstated (a)
+provisionally, unless and until the copyright holder explicitly and
+finally terminates your license, and (b) permanently, if the copyright
+holder fails to notify you of the violation by some reasonable means
+prior to 60 days after the cessation.
+
+ Moreover, your license from a particular copyright holder is
+reinstated permanently if the copyright holder notifies you of the
+violation by some reasonable means, this is the first time you have
+received notice of violation of this License (for any work) from that
+copyright holder, and you cure the violation prior to 30 days after
+your receipt of the notice.
+
+ Termination of your rights under this section does not terminate the
+licenses of parties who have received copies or rights from you under
+this License. If your rights have been terminated and not permanently
+reinstated, you do not qualify to receive new licenses for the same
+material under section 10.
+
+ 9. Acceptance Not Required for Having Copies.
+
+ You are not required to accept this License in order to receive or
+run a copy of the Program. Ancillary propagation of a covered work
+occurring solely as a consequence of using peer-to-peer transmission
+to receive a copy likewise does not require acceptance. However,
+nothing other than this License grants you permission to propagate or
+modify any covered work. These actions infringe copyright if you do
+not accept this License. Therefore, by modifying or propagating a
+covered work, you indicate your acceptance of this License to do so.
+
+ 10. Automatic Licensing of Downstream Recipients.
+
+ Each time you convey a covered work, the recipient automatically
+receives a license from the original licensors, to run, modify and
+propagate that work, subject to this License. You are not responsible
+for enforcing compliance by third parties with this License.
+
+ An "entity transaction" is a transaction transferring control of an
+organization, or substantially all assets of one, or subdividing an
+organization, or merging organizations. If propagation of a covered
+work results from an entity transaction, each party to that
+transaction who receives a copy of the work also receives whatever
+licenses to the work the party's predecessor in interest had or could
+give under the previous paragraph, plus a right to possession of the
+Corresponding Source of the work from the predecessor in interest, if
+the predecessor has it or can get it with reasonable efforts.
+
+ You may not impose any further restrictions on the exercise of the
+rights granted or affirmed under this License. For example, you may
+not impose a license fee, royalty, or other charge for exercise of
+rights granted under this License, and you may not initiate litigation
+(including a cross-claim or counterclaim in a lawsuit) alleging that
+any patent claim is infringed by making, using, selling, offering for
+sale, or importing the Program or any portion of it.
+
+ 11. Patents.
+
+ A "contributor" is a copyright holder who authorizes use under this
+License of the Program or a work on which the Program is based. The
+work thus licensed is called the contributor's "contributor version".
+
+ A contributor's "essential patent claims" are all patent claims
+owned or controlled by the contributor, whether already acquired or
+hereafter acquired, that would be infringed by some manner, permitted
+by this License, of making, using, or selling its contributor version,
+but do not include claims that would be infringed only as a
+consequence of further modification of the contributor version. For
+purposes of this definition, "control" includes the right to grant
+patent sublicenses in a manner consistent with the requirements of
+this License.
+
+ Each contributor grants you a non-exclusive, worldwide, royalty-free
+patent license under the contributor's essential patent claims, to
+make, use, sell, offer for sale, import and otherwise run, modify and
+propagate the contents of its contributor version.
+
+ In the following three paragraphs, a "patent license" is any express
+agreement or commitment, however denominated, not to enforce a patent
+(such as an express permission to practice a patent or covenant not to
+sue for patent infringement). To "grant" such a patent license to a
+party means to make such an agreement or commitment not to enforce a
+patent against the party.
+
+ If you convey a covered work, knowingly relying on a patent license,
+and the Corresponding Source of the work is not available for anyone
+to copy, free of charge and under the terms of this License, through a
+publicly available network server or other readily accessible means,
+then you must either (1) cause the Corresponding Source to be so
+available, or (2) arrange to deprive yourself of the benefit of the
+patent license for this particular work, or (3) arrange, in a manner
+consistent with the requirements of this License, to extend the patent
+license to downstream recipients. "Knowingly relying" means you have
+actual knowledge that, but for the patent license, your conveying the
+covered work in a country, or your recipient's use of the covered work
+in a country, would infringe one or more identifiable patents in that
+country that you have reason to believe are valid.
+
+ If, pursuant to or in connection with a single transaction or
+arrangement, you convey, or propagate by procuring conveyance of, a
+covered work, and grant a patent license to some of the parties
+receiving the covered work authorizing them to use, propagate, modify
+or convey a specific copy of the covered work, then the patent license
+you grant is automatically extended to all recipients of the covered
+work and works based on it.
+
+ A patent license is "discriminatory" if it does not include within
+the scope of its coverage, prohibits the exercise of, or is
+conditioned on the non-exercise of one or more of the rights that are
+specifically granted under this License. You may not convey a covered
+work if you are a party to an arrangement with a third party that is
+in the business of distributing software, under which you make payment
+to the third party based on the extent of your activity of conveying
+the work, and under which the third party grants, to any of the
+parties who would receive the covered work from you, a discriminatory
+patent license (a) in connection with copies of the covered work
+conveyed by you (or copies made from those copies), or (b) primarily
+for and in connection with specific products or compilations that
+contain the covered work, unless you entered into that arrangement,
+or that patent license was granted, prior to 28 March 2007.
+
+ Nothing in this License shall be construed as excluding or limiting
+any implied license or other defenses to infringement that may
+otherwise be available to you under applicable patent law.
+
+ 12. No Surrender of Others' Freedom.
+
+ If conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot convey a
+covered work so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you may
+not convey it at all. For example, if you agree to terms that obligate you
+to collect a royalty for further conveying from those to whom you convey
+the Program, the only way you could satisfy both those terms and this
+License would be to refrain entirely from conveying the Program.
+
+ 13. Use with the GNU Affero General Public License.
+
+ Notwithstanding any other provision of this License, you have
+permission to link or combine any covered work with a work licensed
+under version 3 of the GNU Affero General Public License into a single
+combined work, and to convey the resulting work. The terms of this
+License will continue to apply to the part which is the covered work,
+but the special requirements of the GNU Affero General Public License,
+section 13, concerning interaction through a network will apply to the
+combination as such.
+
+ 14. Revised Versions of this License.
+
+ The Free Software Foundation may publish revised and/or new versions of
+the GNU General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Program specifies that a certain numbered version of the GNU General
+Public License "or any later version" applies to it, you have the
+option of following the terms and conditions either of that numbered
+version or of any later version published by the Free Software
+Foundation. If the Program does not specify a version number of the
+GNU General Public License, you may choose any version ever published
+by the Free Software Foundation.
+
+ If the Program specifies that a proxy can decide which future
+versions of the GNU General Public License can be used, that proxy's
+public statement of acceptance of a version permanently authorizes you
+to choose that version for the Program.
+
+ Later license versions may give you additional or different
+permissions. However, no additional obligations are imposed on any
+author or copyright holder as a result of your choosing to follow a
+later version.
+
+ 15. Disclaimer of Warranty.
+
+ THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
+APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
+HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
+OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
+THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
+IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
+ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+ 16. Limitation of Liability.
+
+ IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
+THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
+GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
+USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
+DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
+PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
+EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
+SUCH DAMAGES.
+
+ 17. Interpretation of Sections 15 and 16.
+
+ If the disclaimer of warranty and limitation of liability provided
+above cannot be given local legal effect according to their terms,
+reviewing courts shall apply local law that most closely approximates
+an absolute waiver of all civil liability in connection with the
+Program, unless a warranty or assumption of liability accompanies a
+copy of the Program in return for a fee.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+state the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ {one line to give the program's name and a brief idea of what it does.}
+ Copyright (C) {year} {name of author}
+
+ This program 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, either version 3 of the License, or
+ (at your option) any later version.
+
+ This program 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 this program. If not, see .
+
+Also add information on how to contact you by electronic and paper mail.
+
+ If the program does terminal interaction, make it output a short
+notice like this when it starts in an interactive mode:
+
+ {project} Copyright (C) {year} {fullname}
+ This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, your program's commands
+might be different; for a GUI interface, you would use an "about box".
+
+ You should also get your employer (if you work as a programmer) or school,
+if any, to sign a "copyright disclaimer" for the program, if necessary.
+For more information on this, and how to apply and follow the GNU GPL, see
+.
+
+ The GNU General Public License does not permit incorporating your program
+into proprietary programs. If your program is a subroutine library, you
+may consider it more useful to permit linking proprietary applications with
+the library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License. But first, please read
+.
diff --git a/Resources/BlitzSteam.LICENSE.lesser b/Resources/BlitzSteam.LICENSE.lesser
index 65c5ca8..b14ca0a 100644
--- a/Resources/BlitzSteam.LICENSE.lesser
+++ b/Resources/BlitzSteam.LICENSE.lesser
@@ -1,165 +1,165 @@
- GNU LESSER GENERAL PUBLIC LICENSE
- Version 3, 29 June 2007
-
- Copyright (C) 2007 Free Software Foundation, Inc.
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-
- This version of the GNU Lesser General Public License incorporates
-the terms and conditions of version 3 of the GNU General Public
-License, supplemented by the additional permissions listed below.
-
- 0. Additional Definitions.
-
- As used herein, "this License" refers to version 3 of the GNU Lesser
-General Public License, and the "GNU GPL" refers to version 3 of the GNU
-General Public License.
-
- "The Library" refers to a covered work governed by this License,
-other than an Application or a Combined Work as defined below.
-
- An "Application" is any work that makes use of an interface provided
-by the Library, but which is not otherwise based on the Library.
-Defining a subclass of a class defined by the Library is deemed a mode
-of using an interface provided by the Library.
-
- A "Combined Work" is a work produced by combining or linking an
-Application with the Library. The particular version of the Library
-with which the Combined Work was made is also called the "Linked
-Version".
-
- The "Minimal Corresponding Source" for a Combined Work means the
-Corresponding Source for the Combined Work, excluding any source code
-for portions of the Combined Work that, considered in isolation, are
-based on the Application, and not on the Linked Version.
-
- The "Corresponding Application Code" for a Combined Work means the
-object code and/or source code for the Application, including any data
-and utility programs needed for reproducing the Combined Work from the
-Application, but excluding the System Libraries of the Combined Work.
-
- 1. Exception to Section 3 of the GNU GPL.
-
- You may convey a covered work under sections 3 and 4 of this License
-without being bound by section 3 of the GNU GPL.
-
- 2. Conveying Modified Versions.
-
- If you modify a copy of the Library, and, in your modifications, a
-facility refers to a function or data to be supplied by an Application
-that uses the facility (other than as an argument passed when the
-facility is invoked), then you may convey a copy of the modified
-version:
-
- a) under this License, provided that you make a good faith effort to
- ensure that, in the event an Application does not supply the
- function or data, the facility still operates, and performs
- whatever part of its purpose remains meaningful, or
-
- b) under the GNU GPL, with none of the additional permissions of
- this License applicable to that copy.
-
- 3. Object Code Incorporating Material from Library Header Files.
-
- The object code form of an Application may incorporate material from
-a header file that is part of the Library. You may convey such object
-code under terms of your choice, provided that, if the incorporated
-material is not limited to numerical parameters, data structure
-layouts and accessors, or small macros, inline functions and templates
-(ten or fewer lines in length), you do both of the following:
-
- a) Give prominent notice with each copy of the object code that the
- Library is used in it and that the Library and its use are
- covered by this License.
-
- b) Accompany the object code with a copy of the GNU GPL and this license
- document.
-
- 4. Combined Works.
-
- You may convey a Combined Work under terms of your choice that,
-taken together, effectively do not restrict modification of the
-portions of the Library contained in the Combined Work and reverse
-engineering for debugging such modifications, if you also do each of
-the following:
-
- a) Give prominent notice with each copy of the Combined Work that
- the Library is used in it and that the Library and its use are
- covered by this License.
-
- b) Accompany the Combined Work with a copy of the GNU GPL and this license
- document.
-
- c) For a Combined Work that displays copyright notices during
- execution, include the copyright notice for the Library among
- these notices, as well as a reference directing the user to the
- copies of the GNU GPL and this license document.
-
- d) Do one of the following:
-
- 0) Convey the Minimal Corresponding Source under the terms of this
- License, and the Corresponding Application Code in a form
- suitable for, and under terms that permit, the user to
- recombine or relink the Application with a modified version of
- the Linked Version to produce a modified Combined Work, in the
- manner specified by section 6 of the GNU GPL for conveying
- Corresponding Source.
-
- 1) Use a suitable shared library mechanism for linking with the
- Library. A suitable mechanism is one that (a) uses at run time
- a copy of the Library already present on the user's computer
- system, and (b) will operate properly with a modified version
- of the Library that is interface-compatible with the Linked
- Version.
-
- e) Provide Installation Information, but only if you would otherwise
- be required to provide such information under section 6 of the
- GNU GPL, and only to the extent that such information is
- necessary to install and execute a modified version of the
- Combined Work produced by recombining or relinking the
- Application with a modified version of the Linked Version. (If
- you use option 4d0, the Installation Information must accompany
- the Minimal Corresponding Source and Corresponding Application
- Code. If you use option 4d1, you must provide the Installation
- Information in the manner specified by section 6 of the GNU GPL
- for conveying Corresponding Source.)
-
- 5. Combined Libraries.
-
- You may place library facilities that are a work based on the
-Library side by side in a single library together with other library
-facilities that are not Applications and are not covered by this
-License, and convey such a combined library under terms of your
-choice, if you do both of the following:
-
- a) Accompany the combined library with a copy of the same work based
- on the Library, uncombined with any other library facilities,
- conveyed under the terms of this License.
-
- b) Give prominent notice with the combined library that part of it
- is a work based on the Library, and explaining where to find the
- accompanying uncombined form of the same work.
-
- 6. Revised Versions of the GNU Lesser General Public License.
-
- The Free Software Foundation may publish revised and/or new versions
-of the GNU Lesser General Public License from time to time. Such new
-versions will be similar in spirit to the present version, but may
-differ in detail to address new problems or concerns.
-
- Each version is given a distinguishing version number. If the
-Library as you received it specifies that a certain numbered version
-of the GNU Lesser General Public License "or any later version"
-applies to it, you have the option of following the terms and
-conditions either of that published version or of any later version
-published by the Free Software Foundation. If the Library as you
-received it does not specify a version number of the GNU Lesser
-General Public License, you may choose any version of the GNU Lesser
-General Public License ever published by the Free Software Foundation.
-
- If the Library as you received it specifies that a proxy can decide
-whether future versions of the GNU Lesser General Public License shall
-apply, that proxy's public statement of acceptance of any version is
-permanent authorization for you to choose that version for the
-Library.
+ GNU LESSER GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc.
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+
+ This version of the GNU Lesser General Public License incorporates
+the terms and conditions of version 3 of the GNU General Public
+License, supplemented by the additional permissions listed below.
+
+ 0. Additional Definitions.
+
+ As used herein, "this License" refers to version 3 of the GNU Lesser
+General Public License, and the "GNU GPL" refers to version 3 of the GNU
+General Public License.
+
+ "The Library" refers to a covered work governed by this License,
+other than an Application or a Combined Work as defined below.
+
+ An "Application" is any work that makes use of an interface provided
+by the Library, but which is not otherwise based on the Library.
+Defining a subclass of a class defined by the Library is deemed a mode
+of using an interface provided by the Library.
+
+ A "Combined Work" is a work produced by combining or linking an
+Application with the Library. The particular version of the Library
+with which the Combined Work was made is also called the "Linked
+Version".
+
+ The "Minimal Corresponding Source" for a Combined Work means the
+Corresponding Source for the Combined Work, excluding any source code
+for portions of the Combined Work that, considered in isolation, are
+based on the Application, and not on the Linked Version.
+
+ The "Corresponding Application Code" for a Combined Work means the
+object code and/or source code for the Application, including any data
+and utility programs needed for reproducing the Combined Work from the
+Application, but excluding the System Libraries of the Combined Work.
+
+ 1. Exception to Section 3 of the GNU GPL.
+
+ You may convey a covered work under sections 3 and 4 of this License
+without being bound by section 3 of the GNU GPL.
+
+ 2. Conveying Modified Versions.
+
+ If you modify a copy of the Library, and, in your modifications, a
+facility refers to a function or data to be supplied by an Application
+that uses the facility (other than as an argument passed when the
+facility is invoked), then you may convey a copy of the modified
+version:
+
+ a) under this License, provided that you make a good faith effort to
+ ensure that, in the event an Application does not supply the
+ function or data, the facility still operates, and performs
+ whatever part of its purpose remains meaningful, or
+
+ b) under the GNU GPL, with none of the additional permissions of
+ this License applicable to that copy.
+
+ 3. Object Code Incorporating Material from Library Header Files.
+
+ The object code form of an Application may incorporate material from
+a header file that is part of the Library. You may convey such object
+code under terms of your choice, provided that, if the incorporated
+material is not limited to numerical parameters, data structure
+layouts and accessors, or small macros, inline functions and templates
+(ten or fewer lines in length), you do both of the following:
+
+ a) Give prominent notice with each copy of the object code that the
+ Library is used in it and that the Library and its use are
+ covered by this License.
+
+ b) Accompany the object code with a copy of the GNU GPL and this license
+ document.
+
+ 4. Combined Works.
+
+ You may convey a Combined Work under terms of your choice that,
+taken together, effectively do not restrict modification of the
+portions of the Library contained in the Combined Work and reverse
+engineering for debugging such modifications, if you also do each of
+the following:
+
+ a) Give prominent notice with each copy of the Combined Work that
+ the Library is used in it and that the Library and its use are
+ covered by this License.
+
+ b) Accompany the Combined Work with a copy of the GNU GPL and this license
+ document.
+
+ c) For a Combined Work that displays copyright notices during
+ execution, include the copyright notice for the Library among
+ these notices, as well as a reference directing the user to the
+ copies of the GNU GPL and this license document.
+
+ d) Do one of the following:
+
+ 0) Convey the Minimal Corresponding Source under the terms of this
+ License, and the Corresponding Application Code in a form
+ suitable for, and under terms that permit, the user to
+ recombine or relink the Application with a modified version of
+ the Linked Version to produce a modified Combined Work, in the
+ manner specified by section 6 of the GNU GPL for conveying
+ Corresponding Source.
+
+ 1) Use a suitable shared library mechanism for linking with the
+ Library. A suitable mechanism is one that (a) uses at run time
+ a copy of the Library already present on the user's computer
+ system, and (b) will operate properly with a modified version
+ of the Library that is interface-compatible with the Linked
+ Version.
+
+ e) Provide Installation Information, but only if you would otherwise
+ be required to provide such information under section 6 of the
+ GNU GPL, and only to the extent that such information is
+ necessary to install and execute a modified version of the
+ Combined Work produced by recombining or relinking the
+ Application with a modified version of the Linked Version. (If
+ you use option 4d0, the Installation Information must accompany
+ the Minimal Corresponding Source and Corresponding Application
+ Code. If you use option 4d1, you must provide the Installation
+ Information in the manner specified by section 6 of the GNU GPL
+ for conveying Corresponding Source.)
+
+ 5. Combined Libraries.
+
+ You may place library facilities that are a work based on the
+Library side by side in a single library together with other library
+facilities that are not Applications and are not covered by this
+License, and convey such a combined library under terms of your
+choice, if you do both of the following:
+
+ a) Accompany the combined library with a copy of the same work based
+ on the Library, uncombined with any other library facilities,
+ conveyed under the terms of this License.
+
+ b) Give prominent notice with the combined library that part of it
+ is a work based on the Library, and explaining where to find the
+ accompanying uncombined form of the same work.
+
+ 6. Revised Versions of the GNU Lesser General Public License.
+
+ The Free Software Foundation may publish revised and/or new versions
+of the GNU Lesser General Public License from time to time. Such new
+versions will be similar in spirit to the present version, but may
+differ in detail to address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Library as you received it specifies that a certain numbered version
+of the GNU Lesser General Public License "or any later version"
+applies to it, you have the option of following the terms and
+conditions either of that published version or of any later version
+published by the Free Software Foundation. If the Library as you
+received it does not specify a version number of the GNU Lesser
+General Public License, you may choose any version of the GNU Lesser
+General Public License ever published by the Free Software Foundation.
+
+ If the Library as you received it specifies that a proxy can decide
+whether future versions of the GNU Lesser General Public License shall
+apply, that proxy's public statement of acceptance of any version is
+permanent authorization for you to choose that version for the
+Library.
diff --git a/Resources/BlitzSteam.bb b/Resources/BlitzSteam.bb
index da3d351..efda130 100644
--- a/Resources/BlitzSteam.bb
+++ b/Resources/BlitzSteam.bb
@@ -574,6 +574,15 @@ Const BS_EMarketingMessageFlags_PlatformLinux = 1 Shl 3
Const BS_EMarketingMessageFlags_PlatformRestrictions = BS_EMarketingMessageFlags_PlatformWindows Or BS_EMarketingMessageFlags_PlatformMac Or BS_EMarketingMessageFlags_PlatformLinux
;[End Block]
+;[Block] Enumeration: EMatchMakingServerResponse
+;------------------------------------------------------------------------------
+;! Enumeration - EMatchMakingServerResponse
+;------------------------------------------------------------------------------
+Const BS_EMatchMakingServerResponse_ServerResponded = 0
+Const BS_EMatchMakingServerResponse_ServerFailedToRespond = 1
+Const BS_EMatchMakingServerResponse_NoServersListedOnMasterServer = 2
+;[End Block]
+
;[Block] Enumeration: ENotificationPosition
;------------------------------------------------------------------------------
;! Enumeration - ENotificationPosition
@@ -1890,6 +1899,6 @@ End Type
;~IDEal Editor Parameters:
;~F#13#26#31#49#60#71#7E#93#C8#E0#F5#101#110#121#14F#166#178#190#1A1#1E2
-;~F#1EB#1F5#20C#216#220#229#232#240#24B#255#26B#27C#295#2A5#314#322#32C#33C#344#351
-;~F#360#36E#378#389#39D#3A0#3B6#3EA#40A#429#525#543#553#560#653#6CC#6FF
+;~F#1EB#1F5#20C#216#220#229#249#254#25E#274#285#29E#2AE#31D#32B#335#345#34D#35A#369
+;~F#377#381#392#3A6#3A9#3BF#3F3#413#432#52E#54C#55C#569#65C#6D5#708
;~C#Blitz3D
\ No newline at end of file
diff --git a/Resources/BlitzSteam.ipf b/Resources/BlitzSteam.ipf
index 2cb969c..fdfa47e 100644
--- a/Resources/BlitzSteam.ipf
+++ b/Resources/BlitzSteam.ipf
@@ -1,21 +1,22 @@
-[IDEal Project file]
-
- Version="1"
- Expanded="False"
- Icon=""
- MainFile="SteamHTMLSurface_Example.bb"
- Compiler="Blitz3D"
- CommandLine=""
-
-
- AbsPath="\Examples" Expanded="True"
-
-
- AbsPath="\BlitzSteam.bb" PrjFolder="" Line="0" Column="0" Tip="0" Visible="False"
- AbsPath="\BlitzSteamUtility.bb" PrjFolder="" Line="0" Column="0" Tip="0" Visible="False"
- AbsPath="\Examples\SteamAPI_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
- AbsPath="\Examples\SteamAppList_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
- AbsPath="\Examples\SteamApps_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
- AbsPath="\Examples\SteamController_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
- AbsPath="\Examples\SteamHTMLSurface_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
-
+[IDEal Project file]
+
+ Version="1"
+ Expanded="True"
+ Icon=""
+ MainFile="SteamMatchmakingServers_Example.bb"
+ Compiler="Blitz3D"
+ CommandLine=""
+
+
+ AbsPath="\Examples" Expanded="True"
+
+
+ AbsPath="\BlitzSteam.bb" PrjFolder="" Line="0" Column="0" Tip="0" Visible="False"
+ AbsPath="\BlitzSteamUtility.bb" PrjFolder="" Line="0" Column="0" Tip="0" Visible="False"
+ AbsPath="\Examples\SteamAPI_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
+ AbsPath="\Examples\SteamAppList_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
+ AbsPath="\Examples\SteamApps_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
+ AbsPath="\Examples\SteamController_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
+ AbsPath="\Examples\SteamHTMLSurface_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
+ AbsPath="\Examples\SteamMatchmakingServers_Example.bb" PrjFolder="\Examples" Line="0" Column="0" Tip="0" Visible="False"
+
diff --git a/Resources/BlitzSteamUtility.bb b/Resources/BlitzSteamUtility.bb
index 01c5f5e..6c7562a 100644
--- a/Resources/BlitzSteamUtility.bb
+++ b/Resources/BlitzSteamUtility.bb
@@ -1,628 +1,628 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-;------------------------------------------------------------------------------
-;! Constants
-;------------------------------------------------------------------------------
-Const BSU_NAME_LENGTH = 4096
-Const BSU_INSTALLDIR_LENGTH = 4096
-Const BSU_APPID_COUNT = 4096
-Const BSU_INSTALLEDDEPOTS_COUNT = 4096
-
-;------------------------------------------------------------------------------
-;! Globals
-;------------------------------------------------------------------------------
-Global BSU_Initialized = False
-Global BSU_IsSteamRunning% = False
-; -- Interfaces
-Global BSU_AppList%
-Global BSU_Apps%
-Global BSU_Client%
-Global BSU_Controller%
-Global BSU_Friends%
-Global BSU_GameServer%
-Global BSU_GameServerStats%
-Global BSU_HTMLSurface%
-Global BSU_HTTP%
-Global BSU_Inventory%
-Global BSU_Matchmaking%
-Global BSU_MatchmakingServers%
-Global BSU_Music%
-Global BSU_MusicRemote%
-Global BSU_Networking%
-Global BSU_RemoteStorage%
-Global BSU_Screenshots%
-Global BSU_UGC%
-Global BSU_UnifiedMessages%
-Global BSU_User%
-Global BSU_UserStats%
-Global BSU_Utils%
-Global BSU_Video%
-
-;[Block] API: Steam
-;------------------------------------------------------------------------------
-;! API: Steam
-;------------------------------------------------------------------------------
-Function BSU_Init()
- BSU_IsSteamRunning = BS_Steam_IsSteamRunning()
- If BSU_IsSteamRunning And BS_Steam_Init() Then
-
- BSU_AppList = BS_AppList()
- BSU_Apps = BS_Apps()
- BSU_Client = BS_Client()
- BSU_Controller = BS_Controller()
- BSU_Friends = BS_Friends()
- BSU_GameServer = BS_GameServer()
- BSU_GameServerStats = BS_GameServerStats()
- BSU_HTMLSurface = BS_HTMLSurface()
- BSU_HTTP = BS_HTTP()
- BSU_Inventory = BS_Inventory()
- BSU_Matchmaking = BS_Matchmaking()
- BSU_MatchmakingServers = BS_MatchmakingServers()
- BSU_Music = BS_Music()
- BSU_MusicRemote = BS_MusicRemote()
- BSU_Networking = BS_Networking()
- BSU_RemoteStorage = BS_RemoteStorage()
- BSU_Screenshots = BS_Screenshots()
- BSU_UGC = BS_UGC()
- BSU_UnifiedMessages = BS_UnifiedMessages()
- BSU_User = BS_User()
- BSU_UserStats = BS_UserStats()
- BSU_Utils = BS_Utils()
- BSU_Video = BS_Video()
-
- BSU_Initialized = True
- EndIf
-End Function
-
-Function BSU_Shutdown()
- If BSU_IsSteamRunning
- BS_GameServer_Shutdown()
- BS_Steam_Shutdown()
-
- BSU_AppList=0
- BSU_Apps=0
- BSU_Client=0
- BSU_Controller=0
- BSU_Friends=0
- BSU_GameServer=0
- BSU_GameServerStats=0
- BSU_HTTP=0
- BSU_HTMLSurface=0
- BSU_Matchmaking=0
- BSU_MatchmakingServers=0
- BSU_Music=0
- BSU_MusicRemote=0
- BSU_Networking=0
- BSU_RemoteStorage=0
- BSU_Screenshots=0
- BSU_UGC=0
- BSU_UnifiedMessages=0
- BSU_User=0
- BSU_UserStats=0
- BSU_Utils=0
- BSU_Video=0
-
- BSU_Initialized = False
- EndIf
-End Function
-;[End Block]
-
-;[Block] API: AppList
-;------------------------------------------------------------------------------
-;! API: AppList
-;------------------------------------------------------------------------------
-Type BSU_App
- Field AppId%
- Field Name$
- Field InstallDir$
-End Type
-Global BSU_AppCount = 0
-
-Function BSU_AppList_GetInstalledApps(BankAppIdsStorage=0, BankAppNameStorage=0, BankAppInstallDirStorage=0)
- Local BankAppIds, BankAppIdsSz = BSU_APPID_COUNT
- Local BankAppName, BankAppNameSz = BSU_NAME_LENGTH
- Local BankAppInstallDir, BankAppInstallDirSz = BSU_INSTALLDIR_LENGTH
- Local AppCount%, InstalledApp.BSU_App
-
- If BSU_Initialized Then
- ; Clear Installed App List
- Delete Each BSU_App
-
- ; Early-Exit to not waste time.
- If BS_AppList_GetNumInstalledApps(BSU_Apps) = 0 Then Return
-
- If BankAppIdsStorage = 0
- ; Create Temporary storage for AppIds.
- BankAppIds = CreateBank(BankAppIdsSz * 4)
- Else
- ; Reuse existing Bank.
- BankAppIds = BankAppIdsStorage
- BankAppIdsSz = Floor(BankSize(BankAppIds) / 4)
- EndIf
-
- ; Request installed apps from Steam.
- BSU_AppCount = BS_AppList_GetInstalledApps(BSU_AppList, BankAppIds, BankAppIdsSz)
-
- ; We don't need to do this if we don't actually have any apps returned.
- If BSU_AppCount > 0 Then
- If BankAppNameStorage = 0 Then
- ; Create temporary storage for name.
- BankAppName = CreateBank(BankAppNameSz)
- Else
- BankAppName = BankAppNameStorage
- BankAppNameSz = BankSize(BankAppName)
- EndIf
- If BankAppInstallDirStorage = 0 Then
- ; Create temporary storage for installdir.
- BankAppInstallDir = CreateBank(BankAppInstallDirSz)
- Else
- BankAppInstallDir = BankAppInstallDirStorage
- BankAppInstallDirSz = BankSize(BankAppInstallDir)
- EndIf
-
- ; Index all apps.
- Local AppIndex
- For AppIndex = 0 To BSU_AppCount - 1
- InstalledApp.BSU_App = New BSU_App
- InstalledApp\AppId = PeekInt(BankAppIds, AppIndex * 4)
- InstalledApp\Name = BSU_AppList_GetAppName(InstalledApp\AppId, BankAppName)
- InstalledApp\InstallDir = BSU_AppList_GetInstallDir(InstalledApp\AppId, BankAppInstallDir)
- Next
-
- ; Free temporary storage for name and installdir.
- If BankAppInstallDirStorage = 0 Then FreeBank BankAppInstallDir
- If BankAppNameStorage = 0 Then FreeBank BankAppName
- EndIf
-
- ; Free temporary storage for AppIds.
- If BankAppIdsStorage = 0 Then FreeBank BankAppIds
- EndIf
-End Function
-
-Function BSU_AppList_GetAppName$(AppID%, BankStorage=0)
- Local Bank, BankSz = BSU_NAME_LENGTH
- Local AppName$
-
- If BSU_Initialized Then
- If BankStorage = 0 Then
- ; Create temporary storage.
- Bank = CreateBank(BankSz)
- Else
- ; Reuse existing Bank.
- Bank = BankStorage
- BankSz = BankSize(Bank)
- EndIf
-
- ; Request App name from Steam.
- BS_AppList_GetAppName(BSU_AppList, AppID, Bank, BankSz)
-
- ; Read returned C-String from Bank.
- AppName$ = BSU_PeekCString(Bank, 0)
-
- ; Free temporary storage.
- If BankStorage = 0 Then FreeBank Bank
- EndIf
-
- ; Return name read.
- Return AppName
-End Function
-
-Function BSU_AppList_GetInstallDir$(AppID%, BankStorage=0)
- Local Bank, BankSz = BSU_INSTALLDIR_LENGTH
- Local AppInstallDir$
-
- If BSU_Initialized Then
- If BankStorage = 0 Then
- ; Create temporary storage.
- Bank = CreateBank(BankSz)
- Else
- ; Reuse existing Bank.
- Bank = BankStorage
- BankSz = BankSize(Bank)
- EndIf
-
- ; Request App name from Steam.
- BS_AppList_GetAppInstallDir(BSU_AppList, AppID, Bank, BankSz)
-
- ; Read returned C-String from Bank.
- AppInstallDir$ = BSU_PeekCString(Bank, 0)
-
- ; Free temporary storage.
- If BankStorage = 0 Then FreeBank Bank
- EndIf
-
- ; Return name read.
- Return AppInstallDir
-End Function
-;[End Block]
-
-;[Block] API: Apps
-;------------------------------------------------------------------------------
-;! API: Apps
-;------------------------------------------------------------------------------
-Type BSU_DLC
- Field AppId%
- Field Available%
- Field Name$
-End Type
-Global BSU_DLCCount
-
-Type BSU_Depot
- Field DepotId%
-End Type
-Global BSU_DepotCount
-
-Function BSU_Apps_GetDLCData(BankAppIdStorage=0, BankAvailableStorage=0, BankNameStorage=0)
- Local BankAppId%, BankAvailable%
- Local BankName%, BankNameSz% = BSU_NAME_LENGTH
- Local DLCCount% = 0
-
- If BSU_Initialized Then
- Delete Each BSU_DLC
-
- BSU_DLCCount = BS_Apps_GetDLCCount(BSU_Apps)
- If BSU_DLCCount > 0
- If BankAppIdStorage = 0 Then
- ; Create temporary storage for AppId.
- BankAppId = CreateBank(4)
- Else
- ; Reuse existing storage.
- BankAppId = BankAppIdStorage
- EndIf
-
- If BankAvailableStorage = 0 Then
- ; Create temporary storage for Availability.
- BankAvailable = CreateBank(4)
- Else
- ; Reuse existing storage.
- BankAvailable = BankAvailableStorage
- EndIf
-
- If BankNameStorage = 0 Then
- ; Create temporary storage for Availability.
- BankName = CreateBank(BankNameSz)
- Else
- ; Reuse existing storage.
- BankName = BankNameStorage
- BankNameSz = BankSize(BankName)
- EndIf
-
- Local DLCIndex%
- For DLCIndex = 0 To BSU_DLCCount - 1
- BSU_Apps_GetDLCDataByIndex(DLCIndex, BankAppId, BankAvailable, BankName)
- Next
-
- ; Free temporary storages.
- If BankNameStorage = 0 Then FreeBank BankName
- If BankAvailableStorage = 0 Then FreeBank BankAvailable
- If BankAppIdStorage = 0 Then FreeBank BankAppId
- EndIf
- EndIf
-End Function
-
-Function BSU_Apps_GetDLCDataByIndex.BSU_DLC(iDLC%, BankAppIdStorage=0, BankAvailableStorage=0, BankNameStorage=0)
- Local BankAppId%, BankAvailable%
- Local BankName%, BankNameSz% = BSU_NAME_LENGTH
- Local DLC.BSU_DLC
-
- If BSU_Initialized Then
- If BankAppIdStorage = 0 Then
- ; Create temporary storage for AppId.
- BankAppId = CreateBank(4)
- Else
- ; Reuse existing storage.
- BankAppId = BankAppIdStorage
- EndIf
-
- If BankAvailableStorage = 0 Then
- ; Create temporary storage for Availability.
- BankAvailable = CreateBank(4)
- Else
- ; Reuse existing storage.
- BankAvailable = BankAvailableStorage
- EndIf
-
- If BankNameStorage = 0 Then
- ; Create temporary storage for Availability.
- BankName = CreateBank(BankNameSz)
- Else
- ; Reuse existing storage.
- BankName = BankNameStorage
- BankNameSz = BankSize(BankName)
- EndIf
-
- ; Request DLC Data from Steam.
- If BS_Apps_GetDLCDataByIndex(BSU_Apps, iDLC, BankAppId, BankAvailable, BankName, BankNameSz)
- ; Create a result DLC object.
- DLC.BSU_DLC = New BSU_DLC
- DLC\AppId = PeekInt(BankAppId, 0)
- DLC\Available = PeekInt(BankAvailable, 0)
- DLC\Name = BSU_PeekCString(BankName, 0)
- EndIf
-
- ; Free temporary storages.
- If BankNameStorage = 0 Then FreeBank BankName
- If BankAvailableStorage = 0 Then FreeBank BankAvailable
- If BankAppIdStorage = 0 Then FreeBank BankAppId
- EndIf
-
- ; Return the result.
- Return DLC
-End Function
-
-Function BSU_Apps_GetCurrentBetaName$(BankNameStorage=0)
- Local BankName, BankNameSz = BSU_NAME_LENGTH
- Local BetaName$ = ""
-
- If BSU_Initialized Then
- If BankNameStorage = 0 Then
- ; Create temporary storage for name.
- BankName = CreateBank(BankNameSz)
- Else
- ; Reuse existing storage.
- BankName = BankNameStorage
- BankNameSz = BankSize(BankName)
- EndIf
-
- ; Request beta name from Steam.
- BS_Apps_GetCurrentBetaName(BSU_Apps, BankName, BankNameSz)
-
- ; Read returned name.
- BetaName = BSU_PeekCString(BankName, 0)
-
- ; Free temporary storage.
- If BankNameStorage = 0 Then FreeBank BankName
- EndIf
-
- ; Return the result.
- Return BetaName
-End Function
-
-Function BSU_Apps_GetInstalledDepots(nAppID%, BankDepotStorage=0)
- Local BankDepot, BankDepotSz = BSU_INSTALLEDDEPOTS_COUNT
- Local DepotCount
-
- If BSU_Initialized Then
- Delete Each BSU_Depot
-
- If BankDepotStorage = 0 Then
- ; Create temporary storage.
- BankDepot = CreateBank(BankDepotSz * 4)
- Else
- ; Reuse existing storage.
- BankDepot = BankDepotStorage
- BankDepotSz = BankSize(BankDepot) / 4
- EndIf
-
- ; Request depots from Steam.
- BSU_DepotCount = BS_Apps_GetInstalledDepots(BSU_Apps, nAppID, BankDepot, BankDepotSz)
-
- ; Read returned depots into objects.
- Local DepotIndex
- For DepotIndex = 0 To BSU_DepotCount - 1
- Local Depot.BSU_Depot = New BSU_Depot
- Depot\DepotId = PeekInt(BankDepot, DepotIndex * 4)
- Next
-
- ; Free temporary storage.
- If BankDepotStorage = 0 Then FreeBank BankDepot
- EndIf
-End Function
-
-Function BSU_Apps_GetAppInstallDir$(nAppID%, BankInstallDirStorage=0)
- Local BankInstallDir, BankInstallDirSz = BSU_INSTALLDIR_LENGTH
- Local InstallDir$
-
- If BSU_Initialized Then
- If BankInstallDirStorage = 0 Then
- ; Create temporary storage.
- BankInstallDir = CreateBank(BankInstallDirSz)
- Else
- ; Reuse existing storage.
- BankInstallDir = BankInstallDirStorage
- BankInstallDirSz = BankSize(BankInstallDir)
- EndIf
-
- ; Request install dir from Steam.
- Local InstallDirLen% = BS_Apps_GetAppInstallDir(BSU_Apps, nAppID, BankInstallDir, BankInstallDirSz)
-
- ; Read returned value.
- InstallDir = BSU_PeekCString(BankInstallDir, 0)
-
- ; Free temporary storage.
- If BankInstallDirStorage = 0 Then FreeBank BankInstallDir
- EndIf
-
- Return InstallDir$
-End Function
-
-Function BSU_Apps_GetDLCDownloadProgress#(nAppID%)
- Local Progress# = 1.0
- If BSU_Initialized
- ; Create temporary storage.
- Local i64_Downloaded, i64_Total
- i64_Downloaded = BU_LongLong_Create()
- i64_Total = BU_LongLong_Create()
-
- ; Request download progress from Steam.
- If BS_Apps_GetDlcDownloadProgressEx(BSU_Apps, nAppID, i64_Downloaded, i64_Total) Then
- Local dDownloaded, dTotal
- dDownloaded = BU_LongLong_ToDouble(i64_Downloaded)
- dTotal = BU_LongLong_ToDouble(i64_Total)
-
- BU_Double_Div(dDownloaded, dTotal)
- Progress = BU_Double_ToFloat(dDownloaded)
-
- BU_Double_Destroy dDownloaded
- BU_Double_Destroy dTotal
- EndIf
-
- ; Free temporary storage.
- BU_LongLong_Destroy i64_Downloaded
- BU_LongLong_Destroy i64_Total
- EndIf
- Return Progress
-End Function
-;[End Block]
-
-;[Block] API: Apps
-;------------------------------------------------------------------------------
-;! API: Friends
-;------------------------------------------------------------------------------
-Type BSU_Friend
- Field SteamID_L, SteamID_R
-
- Field Name$
- Field NickName$
-
- Field Index%
- Field Relationship%
- Field State%
- Field SteamLevel%
-End Type
-Global BSU_FriendCount
-
-Function BSU_Friends_GetFriends(iFriendFlags = BS_EFriendFlags_All)
- If BSU_Initialized Then
- Delete Each BSU_Friend
-
- BSU_FriendCount = BS_Friends_GetFriendCount(BSU_Friends, iFriendFlags)
- If BSU_FriendCount > 0 Then
- Local FriendIndex
- For FriendIndex = 0 To BSU_FriendCount - 1
- Local CSteamID = BS_Friends_GetFriendByIndex(BSU_Friends, FriendIndex, iFriendFlags)
- Local Friend.BSU_Friend = New BSU_Friend
-
- ; Store a 'native' version of the SteamID
- Local SteamID64 = BS_CSteamID_ConvertToUInt64(CSteamID)
- Friend\SteamID_L = BU_LongLong_ToLongHigh(SteamID64)
- Friend\SteamID_R = BU_LongLong_ToLongLow(SteamID64)
- BU_LongLong_Destroy(SteamID64)
-
- ; Names
- Friend\Name = BS_Friends_GetFriendPersonaName(BSU_Friends, CSteamID)
- Friend\NickName = BS_Friends_GetPlayerNickname(BSU_Friends, CSteamID)
-
- ; Other Stuff
- Friend\Index = FriendIndex
- Friend\Relationship = BS_Friends_GetFriendRelationship(BSU_Friends, CSteamID)
- Friend\State = BS_Friends_GetFriendPersonaState(BSU_Friends, CSteamID)
- Friend\SteamLevel = BS_Friends_GetFriendSteamLevel(BSU_Friends, CSteamID)
-
- BS_CSteamID_Destroy(CSteamID)
- Next
- EndIf
- EndIf
-End Function
-
-;[Block] API: GameServer
-;------------------------------------------------------------------------------
-;! API: GameServer
-;------------------------------------------------------------------------------
-Function BSU_GameServer_Init(IPv4%=0, Port%=27015, SteamPort%=27016, QueryPort=27017, ServerMode=BS_EServerMode_AuthenticationAndSecure, Version$="1.0.0.0")
- If BS_SteamGameServer_Init(IPv4, SteamPort, Port, QueryPort, ServerMode, Version) Then
- BSU_GameServer = BS_GameServer()
- BSU_GameServerStats = BS_GameServerStats()
- BSU_HTTP = BS_GameServerHTTP()
- BSU_Inventory = BS_GameServerInventory()
- BSU_Networking = BS_GameServerNetworking()
- BSU_UGC = BS_GameServerUGC()
- BSU_Utils = BS_GameServerUtils()
-
- BSU_Initialized = True
- EndIf
-End Function
-
-Function BSU_GameServer_Shutdown()
- If BSU_Initialized = True
- BS_SteamGameServer_Shutdown()
-
- BSU_GameServer=0
- BSU_GameServerStats=0
- BSU_HTTP=0
- BSU_Inventory=0
- BSU_Networking=0
- BSU_UGC=0
- BSU_Utils=0
-
- BSU_Initialized = False
- EndIf
-End Function
-;[End Block]
-
-;------------------------------------------------------------------------------
-;! API: GameServerStats
-;------------------------------------------------------------------------------
-
-
-
-;[Block] Blitz Stuff
-;----------------------------------------------------------------
-;! Blitz Stuff
-;----------------------------------------------------------------
-; -- Utility
-; Writes a C-String value to a Bank.
-; Returns amount of bytes written.
-Function BSU_PokeCString%(Bank%, Pos%, Value$)
- If Bank Then
- Local BankSz = BankSize(Bank)
-
- If Pos < 0 Then Pos = 0
- If Pos >= BankSz Then Pos = BankSz - 1
-
- Local ValuePos, ValueLen = Len(Value)
- For ValuePos = 1 To ValueLen
- ; Don't write over the edge, we still need space for the 0-byte
- If (Pos + ValuePos) >= (BankSz - 1) Then Exit
-
- PokeByte Bank, Pos + ValuePos, Asc(Mid(Value, ValuePos, 1))
- Next
- PokeByte Bank, Pos + ValuePos, 0
- Return ValuePos
- EndIf
-End Function
-
-; Reads a C-String value from a Bank.
-; Returns read C-String
-Function BSU_PeekCString$(Bank%, Pos%, Len%=-1)
- If Bank Then
- Local BankSz = BankSize(Bank)
-
- If Pos < 0 Then Pos = 0
- If Pos >= BankSz Then Pos = BankSz - 1
-
- Local OutStr$, OutLen = (BankSz - Pos)
- Local BankPos
- For BankPos = 0 To OutLen
- If (Pos + BankPos) >= BankSz Then Exit
-
- Local Value = PeekByte(Bank, Pos + BankPos)
-
- If (Value = 0 And Len = -1) Or (Pos > Len) Then
- Exit
- Else
- OutStr=OutStr+Chr(Value)
- EndIf
- Next
- Return OutStr
- EndIf
-End Function
-;[End Block]
-
-;~IDEal Editor Parameters:
-;~F#3A#5A#7F#86#C3#DF#100#107#10C#13C#16E#18A#1A9#1C4
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+;------------------------------------------------------------------------------
+;! Constants
+;------------------------------------------------------------------------------
+Const BSU_NAME_LENGTH = 4096
+Const BSU_INSTALLDIR_LENGTH = 4096
+Const BSU_APPID_COUNT = 4096
+Const BSU_INSTALLEDDEPOTS_COUNT = 4096
+
+;------------------------------------------------------------------------------
+;! Globals
+;------------------------------------------------------------------------------
+Global BSU_Initialized = False
+Global BSU_IsSteamRunning% = False
+; -- Interfaces
+Global BSU_AppList%
+Global BSU_Apps%
+Global BSU_Client%
+Global BSU_Controller%
+Global BSU_Friends%
+Global BSU_GameServer%
+Global BSU_GameServerStats%
+Global BSU_HTMLSurface%
+Global BSU_HTTP%
+Global BSU_Inventory%
+Global BSU_Matchmaking%
+Global BSU_MatchmakingServers%
+Global BSU_Music%
+Global BSU_MusicRemote%
+Global BSU_Networking%
+Global BSU_RemoteStorage%
+Global BSU_Screenshots%
+Global BSU_UGC%
+Global BSU_UnifiedMessages%
+Global BSU_User%
+Global BSU_UserStats%
+Global BSU_Utils%
+Global BSU_Video%
+
+;[Block] API: Steam
+;------------------------------------------------------------------------------
+;! API: Steam
+;------------------------------------------------------------------------------
+Function BSU_Init()
+ BSU_IsSteamRunning = BS_Steam_IsSteamRunning()
+ If BSU_IsSteamRunning And BS_Steam_Init() Then
+
+ BSU_AppList = BS_AppList()
+ BSU_Apps = BS_Apps()
+ BSU_Client = BS_Client()
+ BSU_Controller = BS_Controller()
+ BSU_Friends = BS_Friends()
+ BSU_GameServer = BS_GameServer()
+ BSU_GameServerStats = BS_GameServerStats()
+ BSU_HTMLSurface = BS_HTMLSurface()
+ BSU_HTTP = BS_HTTP()
+ BSU_Inventory = BS_Inventory()
+ BSU_Matchmaking = BS_Matchmaking()
+ BSU_MatchmakingServers = BS_MatchmakingServers()
+ BSU_Music = BS_Music()
+ BSU_MusicRemote = BS_MusicRemote()
+ BSU_Networking = BS_Networking()
+ BSU_RemoteStorage = BS_RemoteStorage()
+ BSU_Screenshots = BS_Screenshots()
+ BSU_UGC = BS_UGC()
+ BSU_UnifiedMessages = BS_UnifiedMessages()
+ BSU_User = BS_User()
+ BSU_UserStats = BS_UserStats()
+ BSU_Utils = BS_Utils()
+ BSU_Video = BS_Video()
+
+ BSU_Initialized = True
+ EndIf
+End Function
+
+Function BSU_Shutdown()
+ If BSU_IsSteamRunning
+ BS_GameServer_Shutdown()
+ BS_Steam_Shutdown()
+
+ BSU_AppList=0
+ BSU_Apps=0
+ BSU_Client=0
+ BSU_Controller=0
+ BSU_Friends=0
+ BSU_GameServer=0
+ BSU_GameServerStats=0
+ BSU_HTTP=0
+ BSU_HTMLSurface=0
+ BSU_Matchmaking=0
+ BSU_MatchmakingServers=0
+ BSU_Music=0
+ BSU_MusicRemote=0
+ BSU_Networking=0
+ BSU_RemoteStorage=0
+ BSU_Screenshots=0
+ BSU_UGC=0
+ BSU_UnifiedMessages=0
+ BSU_User=0
+ BSU_UserStats=0
+ BSU_Utils=0
+ BSU_Video=0
+
+ BSU_Initialized = False
+ EndIf
+End Function
+;[End Block]
+
+;[Block] API: AppList
+;------------------------------------------------------------------------------
+;! API: AppList
+;------------------------------------------------------------------------------
+Type BSU_App
+ Field AppId%
+ Field Name$
+ Field InstallDir$
+End Type
+Global BSU_AppCount = 0
+
+Function BSU_AppList_GetInstalledApps(BankAppIdsStorage=0, BankAppNameStorage=0, BankAppInstallDirStorage=0)
+ Local BankAppIds, BankAppIdsSz = BSU_APPID_COUNT
+ Local BankAppName, BankAppNameSz = BSU_NAME_LENGTH
+ Local BankAppInstallDir, BankAppInstallDirSz = BSU_INSTALLDIR_LENGTH
+ Local AppCount%, InstalledApp.BSU_App
+
+ If BSU_Initialized Then
+ ; Clear Installed App List
+ Delete Each BSU_App
+
+ ; Early-Exit to not waste time.
+ If BS_AppList_GetNumInstalledApps(BSU_Apps) = 0 Then Return
+
+ If BankAppIdsStorage = 0
+ ; Create Temporary storage for AppIds.
+ BankAppIds = CreateBank(BankAppIdsSz * 4)
+ Else
+ ; Reuse existing Bank.
+ BankAppIds = BankAppIdsStorage
+ BankAppIdsSz = Floor(BankSize(BankAppIds) / 4)
+ EndIf
+
+ ; Request installed apps from Steam.
+ BSU_AppCount = BS_AppList_GetInstalledApps(BSU_AppList, BankAppIds, BankAppIdsSz)
+
+ ; We don't need to do this if we don't actually have any apps returned.
+ If BSU_AppCount > 0 Then
+ If BankAppNameStorage = 0 Then
+ ; Create temporary storage for name.
+ BankAppName = CreateBank(BankAppNameSz)
+ Else
+ BankAppName = BankAppNameStorage
+ BankAppNameSz = BankSize(BankAppName)
+ EndIf
+ If BankAppInstallDirStorage = 0 Then
+ ; Create temporary storage for installdir.
+ BankAppInstallDir = CreateBank(BankAppInstallDirSz)
+ Else
+ BankAppInstallDir = BankAppInstallDirStorage
+ BankAppInstallDirSz = BankSize(BankAppInstallDir)
+ EndIf
+
+ ; Index all apps.
+ Local AppIndex
+ For AppIndex = 0 To BSU_AppCount - 1
+ InstalledApp.BSU_App = New BSU_App
+ InstalledApp\AppId = PeekInt(BankAppIds, AppIndex * 4)
+ InstalledApp\Name = BSU_AppList_GetAppName(InstalledApp\AppId, BankAppName)
+ InstalledApp\InstallDir = BSU_AppList_GetInstallDir(InstalledApp\AppId, BankAppInstallDir)
+ Next
+
+ ; Free temporary storage for name and installdir.
+ If BankAppInstallDirStorage = 0 Then FreeBank BankAppInstallDir
+ If BankAppNameStorage = 0 Then FreeBank BankAppName
+ EndIf
+
+ ; Free temporary storage for AppIds.
+ If BankAppIdsStorage = 0 Then FreeBank BankAppIds
+ EndIf
+End Function
+
+Function BSU_AppList_GetAppName$(AppID%, BankStorage=0)
+ Local Bank, BankSz = BSU_NAME_LENGTH
+ Local AppName$
+
+ If BSU_Initialized Then
+ If BankStorage = 0 Then
+ ; Create temporary storage.
+ Bank = CreateBank(BankSz)
+ Else
+ ; Reuse existing Bank.
+ Bank = BankStorage
+ BankSz = BankSize(Bank)
+ EndIf
+
+ ; Request App name from Steam.
+ BS_AppList_GetAppName(BSU_AppList, AppID, Bank, BankSz)
+
+ ; Read returned C-String from Bank.
+ AppName$ = BSU_PeekCString(Bank, 0)
+
+ ; Free temporary storage.
+ If BankStorage = 0 Then FreeBank Bank
+ EndIf
+
+ ; Return name read.
+ Return AppName
+End Function
+
+Function BSU_AppList_GetInstallDir$(AppID%, BankStorage=0)
+ Local Bank, BankSz = BSU_INSTALLDIR_LENGTH
+ Local AppInstallDir$
+
+ If BSU_Initialized Then
+ If BankStorage = 0 Then
+ ; Create temporary storage.
+ Bank = CreateBank(BankSz)
+ Else
+ ; Reuse existing Bank.
+ Bank = BankStorage
+ BankSz = BankSize(Bank)
+ EndIf
+
+ ; Request App name from Steam.
+ BS_AppList_GetAppInstallDir(BSU_AppList, AppID, Bank, BankSz)
+
+ ; Read returned C-String from Bank.
+ AppInstallDir$ = BSU_PeekCString(Bank, 0)
+
+ ; Free temporary storage.
+ If BankStorage = 0 Then FreeBank Bank
+ EndIf
+
+ ; Return name read.
+ Return AppInstallDir
+End Function
+;[End Block]
+
+;[Block] API: Apps
+;------------------------------------------------------------------------------
+;! API: Apps
+;------------------------------------------------------------------------------
+Type BSU_DLC
+ Field AppId%
+ Field Available%
+ Field Name$
+End Type
+Global BSU_DLCCount
+
+Type BSU_Depot
+ Field DepotId%
+End Type
+Global BSU_DepotCount
+
+Function BSU_Apps_GetDLCData(BankAppIdStorage=0, BankAvailableStorage=0, BankNameStorage=0)
+ Local BankAppId%, BankAvailable%
+ Local BankName%, BankNameSz% = BSU_NAME_LENGTH
+ Local DLCCount% = 0
+
+ If BSU_Initialized Then
+ Delete Each BSU_DLC
+
+ BSU_DLCCount = BS_Apps_GetDLCCount(BSU_Apps)
+ If BSU_DLCCount > 0
+ If BankAppIdStorage = 0 Then
+ ; Create temporary storage for AppId.
+ BankAppId = CreateBank(4)
+ Else
+ ; Reuse existing storage.
+ BankAppId = BankAppIdStorage
+ EndIf
+
+ If BankAvailableStorage = 0 Then
+ ; Create temporary storage for Availability.
+ BankAvailable = CreateBank(4)
+ Else
+ ; Reuse existing storage.
+ BankAvailable = BankAvailableStorage
+ EndIf
+
+ If BankNameStorage = 0 Then
+ ; Create temporary storage for Availability.
+ BankName = CreateBank(BankNameSz)
+ Else
+ ; Reuse existing storage.
+ BankName = BankNameStorage
+ BankNameSz = BankSize(BankName)
+ EndIf
+
+ Local DLCIndex%
+ For DLCIndex = 0 To BSU_DLCCount - 1
+ BSU_Apps_GetDLCDataByIndex(DLCIndex, BankAppId, BankAvailable, BankName)
+ Next
+
+ ; Free temporary storages.
+ If BankNameStorage = 0 Then FreeBank BankName
+ If BankAvailableStorage = 0 Then FreeBank BankAvailable
+ If BankAppIdStorage = 0 Then FreeBank BankAppId
+ EndIf
+ EndIf
+End Function
+
+Function BSU_Apps_GetDLCDataByIndex.BSU_DLC(iDLC%, BankAppIdStorage=0, BankAvailableStorage=0, BankNameStorage=0)
+ Local BankAppId%, BankAvailable%
+ Local BankName%, BankNameSz% = BSU_NAME_LENGTH
+ Local DLC.BSU_DLC
+
+ If BSU_Initialized Then
+ If BankAppIdStorage = 0 Then
+ ; Create temporary storage for AppId.
+ BankAppId = CreateBank(4)
+ Else
+ ; Reuse existing storage.
+ BankAppId = BankAppIdStorage
+ EndIf
+
+ If BankAvailableStorage = 0 Then
+ ; Create temporary storage for Availability.
+ BankAvailable = CreateBank(4)
+ Else
+ ; Reuse existing storage.
+ BankAvailable = BankAvailableStorage
+ EndIf
+
+ If BankNameStorage = 0 Then
+ ; Create temporary storage for Availability.
+ BankName = CreateBank(BankNameSz)
+ Else
+ ; Reuse existing storage.
+ BankName = BankNameStorage
+ BankNameSz = BankSize(BankName)
+ EndIf
+
+ ; Request DLC Data from Steam.
+ If BS_Apps_GetDLCDataByIndex(BSU_Apps, iDLC, BankAppId, BankAvailable, BankName, BankNameSz)
+ ; Create a result DLC object.
+ DLC.BSU_DLC = New BSU_DLC
+ DLC\AppId = PeekInt(BankAppId, 0)
+ DLC\Available = PeekInt(BankAvailable, 0)
+ DLC\Name = BSU_PeekCString(BankName, 0)
+ EndIf
+
+ ; Free temporary storages.
+ If BankNameStorage = 0 Then FreeBank BankName
+ If BankAvailableStorage = 0 Then FreeBank BankAvailable
+ If BankAppIdStorage = 0 Then FreeBank BankAppId
+ EndIf
+
+ ; Return the result.
+ Return DLC
+End Function
+
+Function BSU_Apps_GetCurrentBetaName$(BankNameStorage=0)
+ Local BankName, BankNameSz = BSU_NAME_LENGTH
+ Local BetaName$ = ""
+
+ If BSU_Initialized Then
+ If BankNameStorage = 0 Then
+ ; Create temporary storage for name.
+ BankName = CreateBank(BankNameSz)
+ Else
+ ; Reuse existing storage.
+ BankName = BankNameStorage
+ BankNameSz = BankSize(BankName)
+ EndIf
+
+ ; Request beta name from Steam.
+ BS_Apps_GetCurrentBetaName(BSU_Apps, BankName, BankNameSz)
+
+ ; Read returned name.
+ BetaName = BSU_PeekCString(BankName, 0)
+
+ ; Free temporary storage.
+ If BankNameStorage = 0 Then FreeBank BankName
+ EndIf
+
+ ; Return the result.
+ Return BetaName
+End Function
+
+Function BSU_Apps_GetInstalledDepots(nAppID%, BankDepotStorage=0)
+ Local BankDepot, BankDepotSz = BSU_INSTALLEDDEPOTS_COUNT
+ Local DepotCount
+
+ If BSU_Initialized Then
+ Delete Each BSU_Depot
+
+ If BankDepotStorage = 0 Then
+ ; Create temporary storage.
+ BankDepot = CreateBank(BankDepotSz * 4)
+ Else
+ ; Reuse existing storage.
+ BankDepot = BankDepotStorage
+ BankDepotSz = BankSize(BankDepot) / 4
+ EndIf
+
+ ; Request depots from Steam.
+ BSU_DepotCount = BS_Apps_GetInstalledDepots(BSU_Apps, nAppID, BankDepot, BankDepotSz)
+
+ ; Read returned depots into objects.
+ Local DepotIndex
+ For DepotIndex = 0 To BSU_DepotCount - 1
+ Local Depot.BSU_Depot = New BSU_Depot
+ Depot\DepotId = PeekInt(BankDepot, DepotIndex * 4)
+ Next
+
+ ; Free temporary storage.
+ If BankDepotStorage = 0 Then FreeBank BankDepot
+ EndIf
+End Function
+
+Function BSU_Apps_GetAppInstallDir$(nAppID%, BankInstallDirStorage=0)
+ Local BankInstallDir, BankInstallDirSz = BSU_INSTALLDIR_LENGTH
+ Local InstallDir$
+
+ If BSU_Initialized Then
+ If BankInstallDirStorage = 0 Then
+ ; Create temporary storage.
+ BankInstallDir = CreateBank(BankInstallDirSz)
+ Else
+ ; Reuse existing storage.
+ BankInstallDir = BankInstallDirStorage
+ BankInstallDirSz = BankSize(BankInstallDir)
+ EndIf
+
+ ; Request install dir from Steam.
+ Local InstallDirLen% = BS_Apps_GetAppInstallDir(BSU_Apps, nAppID, BankInstallDir, BankInstallDirSz)
+
+ ; Read returned value.
+ InstallDir = BSU_PeekCString(BankInstallDir, 0)
+
+ ; Free temporary storage.
+ If BankInstallDirStorage = 0 Then FreeBank BankInstallDir
+ EndIf
+
+ Return InstallDir$
+End Function
+
+Function BSU_Apps_GetDLCDownloadProgress#(nAppID%)
+ Local Progress# = 1.0
+ If BSU_Initialized
+ ; Create temporary storage.
+ Local i64_Downloaded, i64_Total
+ i64_Downloaded = BU_LongLong_Create()
+ i64_Total = BU_LongLong_Create()
+
+ ; Request download progress from Steam.
+ If BS_Apps_GetDlcDownloadProgressEx(BSU_Apps, nAppID, i64_Downloaded, i64_Total) Then
+ Local dDownloaded, dTotal
+ dDownloaded = BU_LongLong_ToDouble(i64_Downloaded)
+ dTotal = BU_LongLong_ToDouble(i64_Total)
+
+ BU_Double_Div(dDownloaded, dTotal)
+ Progress = BU_Double_ToFloat(dDownloaded)
+
+ BU_Double_Destroy dDownloaded
+ BU_Double_Destroy dTotal
+ EndIf
+
+ ; Free temporary storage.
+ BU_LongLong_Destroy i64_Downloaded
+ BU_LongLong_Destroy i64_Total
+ EndIf
+ Return Progress
+End Function
+;[End Block]
+
+;[Block] API: Apps
+;------------------------------------------------------------------------------
+;! API: Friends
+;------------------------------------------------------------------------------
+Type BSU_Friend
+ Field SteamID_L, SteamID_R
+
+ Field Name$
+ Field NickName$
+
+ Field Index%
+ Field Relationship%
+ Field State%
+ Field SteamLevel%
+End Type
+Global BSU_FriendCount
+
+Function BSU_Friends_GetFriends(iFriendFlags = BS_EFriendFlags_All)
+ If BSU_Initialized Then
+ Delete Each BSU_Friend
+
+ BSU_FriendCount = BS_Friends_GetFriendCount(BSU_Friends, iFriendFlags)
+ If BSU_FriendCount > 0 Then
+ Local FriendIndex
+ For FriendIndex = 0 To BSU_FriendCount - 1
+ Local CSteamID = BS_Friends_GetFriendByIndex(BSU_Friends, FriendIndex, iFriendFlags)
+ Local Friend.BSU_Friend = New BSU_Friend
+
+ ; Store a 'native' version of the SteamID
+ Local SteamID64 = BS_CSteamID_ConvertToUInt64(CSteamID)
+ Friend\SteamID_L = BU_LongLong_ToLongHigh(SteamID64)
+ Friend\SteamID_R = BU_LongLong_ToLongLow(SteamID64)
+ BU_LongLong_Destroy(SteamID64)
+
+ ; Names
+ Friend\Name = BS_Friends_GetFriendPersonaName(BSU_Friends, CSteamID)
+ Friend\NickName = BS_Friends_GetPlayerNickname(BSU_Friends, CSteamID)
+
+ ; Other Stuff
+ Friend\Index = FriendIndex
+ Friend\Relationship = BS_Friends_GetFriendRelationship(BSU_Friends, CSteamID)
+ Friend\State = BS_Friends_GetFriendPersonaState(BSU_Friends, CSteamID)
+ Friend\SteamLevel = BS_Friends_GetFriendSteamLevel(BSU_Friends, CSteamID)
+
+ BS_CSteamID_Destroy(CSteamID)
+ Next
+ EndIf
+ EndIf
+End Function
+
+;[Block] API: GameServer
+;------------------------------------------------------------------------------
+;! API: GameServer
+;------------------------------------------------------------------------------
+Function BSU_GameServer_Init(IPv4%=0, Port%=27015, SteamPort%=27016, QueryPort=27017, ServerMode=BS_EServerMode_AuthenticationAndSecure, Version$="1.0.0.0")
+ If BS_SteamGameServer_Init(IPv4, SteamPort, Port, QueryPort, ServerMode, Version) Then
+ BSU_GameServer = BS_GameServer()
+ BSU_GameServerStats = BS_GameServerStats()
+ BSU_HTTP = BS_GameServerHTTP()
+ BSU_Inventory = BS_GameServerInventory()
+ BSU_Networking = BS_GameServerNetworking()
+ BSU_UGC = BS_GameServerUGC()
+ BSU_Utils = BS_GameServerUtils()
+
+ BSU_Initialized = True
+ EndIf
+End Function
+
+Function BSU_GameServer_Shutdown()
+ If BSU_Initialized = True
+ BS_SteamGameServer_Shutdown()
+
+ BSU_GameServer=0
+ BSU_GameServerStats=0
+ BSU_HTTP=0
+ BSU_Inventory=0
+ BSU_Networking=0
+ BSU_UGC=0
+ BSU_Utils=0
+
+ BSU_Initialized = False
+ EndIf
+End Function
+;[End Block]
+
+;------------------------------------------------------------------------------
+;! API: GameServerStats
+;------------------------------------------------------------------------------
+
+
+
+;[Block] Blitz Stuff
+;----------------------------------------------------------------
+;! Blitz Stuff
+;----------------------------------------------------------------
+; -- Utility
+; Writes a C-String value to a Bank.
+; Returns amount of bytes written.
+Function BSU_PokeCString%(Bank%, Pos%, Value$)
+ If Bank Then
+ Local BankSz = BankSize(Bank)
+
+ If Pos < 0 Then Pos = 0
+ If Pos >= BankSz Then Pos = BankSz - 1
+
+ Local ValuePos, ValueLen = Len(Value)
+ For ValuePos = 1 To ValueLen
+ ; Don't write over the edge, we still need space for the 0-byte
+ If (Pos + ValuePos) >= (BankSz - 1) Then Exit
+
+ PokeByte Bank, Pos + ValuePos, Asc(Mid(Value, ValuePos, 1))
+ Next
+ PokeByte Bank, Pos + ValuePos, 0
+ Return ValuePos
+ EndIf
+End Function
+
+; Reads a C-String value from a Bank.
+; Returns read C-String
+Function BSU_PeekCString$(Bank%, Pos%, Len%=-1)
+ If Bank Then
+ Local BankSz = BankSize(Bank)
+
+ If Pos < 0 Then Pos = 0
+ If Pos >= BankSz Then Pos = BankSz - 1
+
+ Local OutStr$, OutLen = (BankSz - Pos)
+ Local BankPos
+ For BankPos = 0 To OutLen
+ If (Pos + BankPos) >= BankSz Then Exit
+
+ Local Value = PeekByte(Bank, Pos + BankPos)
+
+ If (Value = 0 And Len = -1) Or (Pos > Len) Then
+ Exit
+ Else
+ OutStr=OutStr+Chr(Value)
+ EndIf
+ Next
+ Return OutStr
+ EndIf
+End Function
+;[End Block]
+
+;~IDEal Editor Parameters:
+;~F#3A#5A#7F#86#C3#DF#100#107#10C#13C#16E#18A#1A9#1C4
;~C#Blitz3D
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam.decls b/Resources/Decls/BlitzSteam.decls
index 0760b0f..032af34 100644
--- a/Resources/Decls/BlitzSteam.decls
+++ b/Resources/Decls/BlitzSteam.decls
@@ -1,20 +1,23 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-; Generic ---------------------------------------------------------------------
-BS_Helper_FormatUnixTime$(unixTime%, pchFormat$) :"_BS_Helper_FormatUnixTime@8"
-BS_Helper_CopyMemoryIntMangle(pSource%, pDest%, iMangling%, iSourceW%, iSourceH%, iDestW%, iDestH%, iAreaX%, iAreaY%, iAreaW%, iAreaH%):"_BS_Helper_CopyMemoryIntMangle@44"
\ No newline at end of file
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+; Generic ---------------------------------------------------------------------
+BS_Helper_FormatUnixTime$(unixTime%, pchFormat$) :"_BS_Helper_FormatUnixTime@8"
+BS_Helper_CopyMemoryIntMangle(pSource%, pDest%, iMangling%, iSourceW%, iSourceH%, iDestW%, iDestH%, iAreaX%, iAreaY%, iAreaW%, iAreaH%):"_BS_Helper_CopyMemoryIntMangle@44"
+
+BS_BlitzPointer_GetReturnAddress%() :"_BS_BlitzPointer_GetReturnAddress@0"
+BS_BlitzPointer_GetFunctionPointer%() :"_BS_BlitzPointer_GetFunctionPointer@0"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_Callback.decls b/Resources/Decls/BlitzSteam_Callback.decls
new file mode 100644
index 0000000..ff20199
--- /dev/null
+++ b/Resources/Decls/BlitzSteam_Callback.decls
@@ -0,0 +1,33 @@
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+; BlitzCallback ---------------------------------------------------------------
+BS_Callback_New%(pFunction%) :"_BS_Callback_New@4"
+BS_Callback_Destroy(pThis%) :"_BS_Callback_Destroy@4"
+BS_Callback_GetCallbackSizeBytes%(pThis%) :"_BS_Callback_GetCallbackSizeBytes@4"
+BS_Callback_SetCallback(pThis%, iCallback%) :"_BS_Callback_SetCallback@8"
+BS_Callback_GetCallback%(pThis%) :"_BS_Callback_GetCallback@4"
+BS_Callback_SetFunction(pThis%, pFunction%) :"_BS_Callback_SetFunction@8"
+BS_Callback_GetFunction%(pThis%) :"_BS_Callback_GetFunction@4"
+BS_Callback_SetRegistered(pThis%, bIsRegistered%) :"_BS_Callback_SetRegistered@8"
+BS_Callback_IsRegistered%(pThis%) :"_BS_Callback_IsRegistered@4"
+BS_Callback_SetGameServer(pThis%, bIsGameServer%) :"_BS_Callback_SetGameServer@8"
+BS_Callback_IsGameServer%(pThis%) :"_BS_Callback_IsGameServer@4"
+BS_Callback_Register(pThis%, iCallback%) :"_BS_Callback_Register@8"
+BS_Callback_Unregister(pThis%) :"_BS_Callback_Unregister@4"
+BS_Callback_RegisterResult(pThis%, lSteamAPICall%, iCallback%) :"_BS_Callback_RegisterResult@12"
+BS_Callback_UnregisterResult(pThis%) :"_BS_Callback_UnregisterResult@4"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_Double.decls b/Resources/Decls/BlitzSteam_Double.decls
index 91ee831..f2d0bce 100644
--- a/Resources/Decls/BlitzSteam_Double.decls
+++ b/Resources/Decls/BlitzSteam_Double.decls
@@ -1,42 +1,42 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; aDouble with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-; Double ------------------------------------------------------------------------
-BS_Double_New%() :"_BS_Double_New@0"
-BS_Double_Copy%(pThis%) :"_BS_Double_Copy@4"
-BS_Double_Destroy(pThis%) :"_BS_Double_Destroy@4"
-BS_Double_ToString$(pThis%) :"_BS_Double_ToString@4"
-BS_Double_FromString%(cString$) :"_BS_Double_FromString@4"
-BS_Double_FromF%(Float#) :"_BS_Double_FromF@4"
-BS_Double_ToF#(pThis%) :"_BS_Double_ToF@4"
-BS_Double_FromI%(iRight%) :"_BS_Double_FromI@4"
-BS_Double_ToI%(pThis%) :"_BS_Double_ToI@8"
-BS_Double_FromL(pDouble%) :"_BS_Double_FromL@4"
-BS_Double_ToL(pThis%) :"_BS_Double_ToL@4"
-BS_Double_Compare%(pThis%, pOther%) :"_BS_Double_Compare@8"
-BS_Double_Set%(pThis%, pOther%) :"_BS_Double_Set@8"
-BS_Double_Add%(pThis%, pOther%) :"_BS_Double_Add@8"
-BS_Double_Sub%(pThis%, pOther%) :"_BS_Double_Sub@8"
-BS_Double_Div%(pThis%, pOther%) :"_BS_Double_Div@8"
-BS_Double_Mul%(pThis%, pOther%) :"_BS_Double_Mul@8"
-BS_Double_Mod%(pThis%, pOther%) :"_BS_Double_Mod@8"
-BS_Double_SetF%(pThis%, fOther%) :"_BS_Double_SetF@8"
-BS_Double_AddF%(pThis%, fOther%) :"_BS_Double_AddF@8"
-BS_Double_SubF%(pThis%, fOther%) :"_BS_Double_SubF@8"
-BS_Double_DivF%(pThis%, fOther%) :"_BS_Double_DivF@8"
-BS_Double_MulF%(pThis%, fOther%) :"_BS_Double_MulF@8"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; aDouble with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+; Double ------------------------------------------------------------------------
+BS_Double_New%() :"_BS_Double_New@0"
+BS_Double_Copy%(pThis%) :"_BS_Double_Copy@4"
+BS_Double_Destroy(pThis%) :"_BS_Double_Destroy@4"
+BS_Double_ToString$(pThis%) :"_BS_Double_ToString@4"
+BS_Double_FromString%(cString$) :"_BS_Double_FromString@4"
+BS_Double_FromF%(Float#) :"_BS_Double_FromF@4"
+BS_Double_ToF#(pThis%) :"_BS_Double_ToF@4"
+BS_Double_FromI%(iRight%) :"_BS_Double_FromI@4"
+BS_Double_ToI%(pThis%) :"_BS_Double_ToI@8"
+BS_Double_FromL(pDouble%) :"_BS_Double_FromL@4"
+BS_Double_ToL(pThis%) :"_BS_Double_ToL@4"
+BS_Double_Compare%(pThis%, pOther%) :"_BS_Double_Compare@8"
+BS_Double_Set%(pThis%, pOther%) :"_BS_Double_Set@8"
+BS_Double_Add%(pThis%, pOther%) :"_BS_Double_Add@8"
+BS_Double_Sub%(pThis%, pOther%) :"_BS_Double_Sub@8"
+BS_Double_Div%(pThis%, pOther%) :"_BS_Double_Div@8"
+BS_Double_Mul%(pThis%, pOther%) :"_BS_Double_Mul@8"
+BS_Double_Mod%(pThis%, pOther%) :"_BS_Double_Mod@8"
+BS_Double_SetF%(pThis%, fOther%) :"_BS_Double_SetF@8"
+BS_Double_AddF%(pThis%, fOther%) :"_BS_Double_AddF@8"
+BS_Double_SubF%(pThis%, fOther%) :"_BS_Double_SubF@8"
+BS_Double_DivF%(pThis%, fOther%) :"_BS_Double_DivF@8"
+BS_Double_MulF%(pThis%, fOther%) :"_BS_Double_MulF@8"
BS_Double_ModF%(pThis%, fOther%) :"_BS_Double_ModF@8"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_Memory.decls b/Resources/Decls/BlitzSteam_Memory.decls
index d705658..8db029f 100644
--- a/Resources/Decls/BlitzSteam_Memory.decls
+++ b/Resources/Decls/BlitzSteam_Memory.decls
@@ -1,33 +1,33 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-; Memory ----------------------------------------------------------------------
-BS_Memory_Alloc%(iSize%) :"_BS_Memory_Alloc@4"
-BS_Memory_ReAlloc%(pMemory%, iSize%) :"_BS_Memory_ReAlloc@8"
-BS_Memory_Free(pMemory%) :"_BS_Memory_Free@4"
-BS_Memory_PokeByte(pMemory%, iOffset%, bValue%) :"_BS_Memory_PokeByte@12"
-BS_Memory_PeekByte%(pMemory%, iOffset%) :"_BS_Memory_PeekByte@8"
-BS_Memory_PokeShort(pMemory%, iOffset%, sValue%) :"_BS_Memory_PokeShort@12"
-BS_Memory_PeekShort%(pMemory%, iOffset%) :"_BS_Memory_PeekShort@8"
-BS_Memory_PokeInt(pMemory%, iOffset%, iValue%) :"_BS_Memory_PokeInt@12"
-BS_Memory_PeekInt%(pMemory%, iOffset%) :"_BS_Memory_PeekInt@8"
-BS_Memory_PokeFloat(pMemory%, iOffset%, fValue#) :"_BS_Memory_PokeFloat@12"
-BS_Memory_PeekFloat#(pMemory%, iOffset%) :"_BS_Memory_PeekFloat@8"
-BS_Memory_PokeLong(pMemory%, iOffset%, lValue%) :"_BS_Memory_PokeLong@12"
-BS_Memory_PeekLong%(pMemory%, iOffset%) :"_BS_Memory_PeekLong@8"
-BS_Memory_PokeDouble(pMemory%, iOffset%, dValue%) :"_BS_Memory_PokeDouble@12"
-BS_Memory_PeekDouble%(pMemory%, iOffset%) :"_BS_Memory_PeekDouble@8"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+; Memory ----------------------------------------------------------------------
+BS_Memory_Alloc%(iSize%) :"_BS_Memory_Alloc@4"
+BS_Memory_ReAlloc%(pMemory%, iSize%) :"_BS_Memory_ReAlloc@8"
+BS_Memory_Free(pMemory%) :"_BS_Memory_Free@4"
+BS_Memory_PokeByte(pMemory%, iOffset%, bValue%) :"_BS_Memory_PokeByte@12"
+BS_Memory_PeekByte%(pMemory%, iOffset%) :"_BS_Memory_PeekByte@8"
+BS_Memory_PokeShort(pMemory%, iOffset%, sValue%) :"_BS_Memory_PokeShort@12"
+BS_Memory_PeekShort%(pMemory%, iOffset%) :"_BS_Memory_PeekShort@8"
+BS_Memory_PokeInt(pMemory%, iOffset%, iValue%) :"_BS_Memory_PokeInt@12"
+BS_Memory_PeekInt%(pMemory%, iOffset%) :"_BS_Memory_PeekInt@8"
+BS_Memory_PokeFloat(pMemory%, iOffset%, fValue#) :"_BS_Memory_PokeFloat@12"
+BS_Memory_PeekFloat#(pMemory%, iOffset%) :"_BS_Memory_PeekFloat@8"
+BS_Memory_PokeLong(pMemory%, iOffset%, lValue%) :"_BS_Memory_PokeLong@12"
+BS_Memory_PeekLong%(pMemory%, iOffset%) :"_BS_Memory_PeekLong@8"
+BS_Memory_PokeDouble(pMemory%, iOffset%, dValue%) :"_BS_Memory_PokeDouble@12"
+BS_Memory_PeekDouble%(pMemory%, iOffset%) :"_BS_Memory_PeekDouble@8"
diff --git a/Resources/Decls/BlitzSteam_SteamGameServer.decls b/Resources/Decls/BlitzSteam_SteamGameServer.decls
index 7095cac..d91bf2c 100644
--- a/Resources/Decls/BlitzSteam_SteamGameServer.decls
+++ b/Resources/Decls/BlitzSteam_SteamGameServer.decls
@@ -1,77 +1,77 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; GameServer ------------------------------------------------------------------
-BS_SteamGameServer_Init%(iIP%, sSteamPort%, sGamePort%, sQueryPort%, EServerMode%, cVersion$):"_BS_SteamGameServer_Init@24"
-BS_SteamGameServer_Shutdown() :"_BS_SteamGameServer_Shutdown@0"
-BS_SteamGameServer_RunCallbacks() :"_BS_SteamGameServer_RunCallbacks@0"
-BS_SteamGameServer_GetHSteamPipe%() :"_BS_SteamGameServer_GetHSteamPipe@0"
-BS_SteamGameServer_IsSecure%() :"_BS_SteamGameServer_IsSecure@0"
-BS_SteamGameServer_GetSteamID%() :"_BS_SteamGameServer_GetSteamID@0"
-;! Function above returns a CSteamID*, clean it up afterwards!
-BS_SteamGameServer%() :"_BS_SteamGameServer@0"
-BS_ISteamGameServer_InitGameServer%(pThis%, iIP%, sGamePort%, sQueryPort%, iFlags%, iAppId%, cVersion$):"_BS_ISteamGameServer_InitGameServer@24"
-BS_ISteamGameServer_SetProduct(pThis%, cProduct$) :"_BS_ISteamGameServer_SetProduct@8"
-BS_ISteamGameServer_SetGameDescription(pThis%, cDescription$) :"_BS_ISteamGameServer_SetGameDescription@8"
-BS_ISteamGameServer_SetModDir(pThis%, cDirectory$) :"_BS_ISteamGameServer_SetModDir@8"
-BS_ISteamGameServer_SetDedicatedServer(pThis%, bDedicated%) :"_BS_ISteamGameServer_SetDedicatedServer@8"
-BS_ISteamGameServer_LogOn(pThis%, cToken$) :"_BS_ISteamGameServer_LogOn@8"
-BS_ISteamGameServer_LogOnAnonymous(pThis%) :"_BS_ISteamGameServer_LogOnAnonymous@4"
-BS_ISteamGameServer_LogOff(pThis%) :"_BS_ISteamGameServer_LogOff@4"
-BS_ISteamGameServer_IsLoggedOn%(pThis%) :"_BS_ISteamGameServer_IsLoggedOn@4"
-BS_ISteamGameServer_IsSecure%(pThis%) :"_BS_ISteamGameServer_IsSecure@4"
-BS_ISteamGameServer_GetSteamID%(pThis%) :"_BS_ISteamGameServer_GetSteamID@4"
-BS_ISteamGameServer_WasRestartRequested%(pThis%) :"_BS_ISteamGameServer_WasRestartRequested@4"
-BS_ISteamGameServer_SetMaxPlayerCount(pThis%, iMaxPlayers%) :"_BS_ISteamGameServer_SetMaxPlayerCount@8"
-BS_ISteamGameServer_SetBotPlayerCount(pThis%, iBotPlayers%) :"_BS_ISteamGameServer_SetBotPlayerCount@8"
-BS_ISteamGameServer_SetServerName(pThis%, cName$) :"_BS_ISteamGameServer_SetServerName@8"
-BS_ISteamGameServer_SetMapName(pThis%, cName$) :"_BS_ISteamGameServer_SetMapName@8"
-BS_ISteamGameServer_SetPasswordProtected(pThis%, bPassworded%) :"_BS_ISteamGameServer_SetPasswordProtected@8"
-BS_ISteamGameServer_SetSpectatorPort(pThis%, sPort%) :"_BS_ISteamGameServer_SetSpectatorPort@8"
-BS_ISteamGameServer_SetSpectatorServerName(pThis%, cName$) :"_BS_ISteamGameServer_SetSpectatorServerName@8"
-BS_ISteamGameServer_ClearAllKeyValues(pThis%) :"_BS_ISteamGameServer_ClearAllKeyValues@4"
-BS_ISteamGameServer_SetKeyValue(pThis%, cKey$, cValue$) :"_BS_ISteamGameServer_SetKeyValue@12"
-BS_ISteamGameServer_SetGameTags(pThis%, cTags$) :"_BS_ISteamGameServer_SetGameTags@8"
-BS_ISteamGameServer_SetGameData(pThis%, cData$) :"_BS_ISteamGameServer_SetGameData@8"
-BS_ISteamGameServer_SetRegion(pThis%, cRegion$) :"_BS_ISteamGameServer_SetRegion@8"
-BS_ISteamGameServer_SendUserConnectAndAuthenticate%(pThis%, iIP%, pAuthBlob*, iAuthBlobSize%, lSteamId%):"_BS_ISteamGameServer_SendUserConnectAndAuthenticate@20"
-BS_ISteamGameServer_SendUserConnectAndAuthenticateEx%(pThis%, iIP%, pAuthBlob%, iAuthBlobSize%, lSteamId%):"_BS_ISteamGameServer_SendUserConnectAndAuthenticate@20"
-BS_ISteamGameServer_CreateUnauthenticatedUserConnection%(pThis%) :"_BS_ISteamGameServer_CreateUnauthenticatedUserConnection@4"
-;! Function above returns a CSteamID*, clean it up afterwards!
-BS_ISteamGameServer_SendUserDisconnect(pThis%, lSteamId%) :"_BS_ISteamGameServer_SendUserDisconnect@8"
-BS_ISteamGameServer_UpdateUserData%(pThis%, lSteamId%, cName$, iScore%):"_BS_ISteamGameServer_UpdateUserData@16"
-BS_ISteamGameServer_GetAuthSessionTicket%(pThis%, pTicket*, iTicketSize%, piTicketSize*):"_BS_ISteamGameServer_GetAuthSessionTicket@16"
-BS_ISteamGameServer_GetAuthSessionTicketEx%(pThis%, pTicket%, iTicketSize%, piTicketSize%):"_BS_ISteamGameServer_GetAuthSessionTicket@16"
-BS_ISteamGameServer_BeginAuthSession%(pThis%, pTicket*, iTicketSize%, lSteamId%):"_BS_ISteamGameServer_BeginAuthSession@16"
-BS_ISteamGameServer_BeginAuthSessionEx%(pThis%, pTicket%, iTicketSize%, lSteamId%):"_BS_ISteamGameServer_BeginAuthSession@16"
-BS_ISteamGameServer_EndAuthSession(pThis%, lSteamId%) :"_BS_ISteamGameServer_EndAuthSession@8"
-BS_ISteamGameServer_CancelAuthTicket(pThis%, iAuthTicket%) :"_BS_ISteamGameServer_CancelAuthTicket@8"
-BS_ISteamGameServer_UserHasLicenseForApp%(pThis%, lSteamId%, iAppId%) :"_BS_ISteamGameServer_UserHasLicenseForApp@12"
-BS_ISteamGameServer_RequestUserGroupStatus%(pThis%, lSteamId%, pSteamIdGroup%) :"_BS_ISteamGameServer_RequestUserGroupStatus@12"
-BS_ISteamGameServer_GetPublicIP%(pThis%) :"_BS_ISteamGameServer_GetPublicIP@4"
-BS_ISteamGameServer_HandleIncomingPacket%(pThis%, pBuffer*, iBufferSize%, iIP%, sPort%):"_BS_ISteamGameServer_HandleIncomingPacket@20"
-BS_ISteamGameServer_HandleIncomingPacketEx%(pThis%, pBuffer%, iBufferSize%, iIP%, sPort%):"_BS_ISteamGameServer_HandleIncomingPacket@20"
-BS_ISteamGameServer_GetNextOutgoingPacket%(pThis%, pBuffer*, iBufferSize%, piIP*, psPort*):"_BS_ISteamGameServer_GetNextOutgoingPacket@20"
-BS_ISteamGameServer_GetNextOutgoingPacketEx%(pThis%, pBuffer%, iBufferSize%, piIP%, psPort%):"_BS_ISteamGameServer_GetNextOutgoingPacket@20"
-BS_ISteamGameServer_EnableHeartbeats(pThis%, bActive%) :"_BS_ISteamGameServer_EnableHeartbeats@8"
-BS_ISteamGameServer_SetHeartbeatInterval(pThis%, iInterval%) :"_BS_ISteamGameServer_SetHeartbeatInterval@8"
-BS_ISteamGameServer_ForceHeartbeat(pThis%) :"_BS_ISteamGameServer_ForceHeartbeat@4"
-BS_ISteamGameServer_AssociateWithClan%(pThis%, pSteamIDClan%) :"_BS_ISteamGameServer_AssociateWithClan@8"
-;! Function above returns a SteamAPICall_t*, clean it up afterwards!
-BS_ISteamGameServer_ComputeNewPlayerCompatibility%(pThis%, pSteamIDNewPlayer%) :"_BS_ISteamGameServer_ComputeNewPlayerCompatibility@8"
-;! Function above returns a SteamAPICall_t*, clean it up afterwards!
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; GameServer ------------------------------------------------------------------
+BS_SteamGameServer_Init%(iIP%, sSteamPort%, sGamePort%, sQueryPort%, EServerMode%, cVersion$):"_BS_SteamGameServer_Init@24"
+BS_SteamGameServer_Shutdown() :"_BS_SteamGameServer_Shutdown@0"
+BS_SteamGameServer_RunCallbacks() :"_BS_SteamGameServer_RunCallbacks@0"
+BS_SteamGameServer_GetHSteamPipe%() :"_BS_SteamGameServer_GetHSteamPipe@0"
+BS_SteamGameServer_IsSecure%() :"_BS_SteamGameServer_IsSecure@0"
+BS_SteamGameServer_GetSteamID%() :"_BS_SteamGameServer_GetSteamID@0"
+;! Function above returns a CSteamID*, clean it up afterwards!
+BS_SteamGameServer%() :"_BS_SteamGameServer@0"
+BS_ISteamGameServer_InitGameServer%(pThis%, iIP%, sGamePort%, sQueryPort%, iFlags%, iAppId%, cVersion$):"_BS_ISteamGameServer_InitGameServer@24"
+BS_ISteamGameServer_SetProduct(pThis%, cProduct$) :"_BS_ISteamGameServer_SetProduct@8"
+BS_ISteamGameServer_SetGameDescription(pThis%, cDescription$) :"_BS_ISteamGameServer_SetGameDescription@8"
+BS_ISteamGameServer_SetModDir(pThis%, cDirectory$) :"_BS_ISteamGameServer_SetModDir@8"
+BS_ISteamGameServer_SetDedicatedServer(pThis%, bDedicated%) :"_BS_ISteamGameServer_SetDedicatedServer@8"
+BS_ISteamGameServer_LogOn(pThis%, cToken$) :"_BS_ISteamGameServer_LogOn@8"
+BS_ISteamGameServer_LogOnAnonymous(pThis%) :"_BS_ISteamGameServer_LogOnAnonymous@4"
+BS_ISteamGameServer_LogOff(pThis%) :"_BS_ISteamGameServer_LogOff@4"
+BS_ISteamGameServer_IsLoggedOn%(pThis%) :"_BS_ISteamGameServer_IsLoggedOn@4"
+BS_ISteamGameServer_IsSecure%(pThis%) :"_BS_ISteamGameServer_IsSecure@4"
+BS_ISteamGameServer_GetSteamID%(pThis%) :"_BS_ISteamGameServer_GetSteamID@4"
+BS_ISteamGameServer_WasRestartRequested%(pThis%) :"_BS_ISteamGameServer_WasRestartRequested@4"
+BS_ISteamGameServer_SetMaxPlayerCount(pThis%, iMaxPlayers%) :"_BS_ISteamGameServer_SetMaxPlayerCount@8"
+BS_ISteamGameServer_SetBotPlayerCount(pThis%, iBotPlayers%) :"_BS_ISteamGameServer_SetBotPlayerCount@8"
+BS_ISteamGameServer_SetServerName(pThis%, cName$) :"_BS_ISteamGameServer_SetServerName@8"
+BS_ISteamGameServer_SetMapName(pThis%, cName$) :"_BS_ISteamGameServer_SetMapName@8"
+BS_ISteamGameServer_SetPasswordProtected(pThis%, bPassworded%) :"_BS_ISteamGameServer_SetPasswordProtected@8"
+BS_ISteamGameServer_SetSpectatorPort(pThis%, sPort%) :"_BS_ISteamGameServer_SetSpectatorPort@8"
+BS_ISteamGameServer_SetSpectatorServerName(pThis%, cName$) :"_BS_ISteamGameServer_SetSpectatorServerName@8"
+BS_ISteamGameServer_ClearAllKeyValues(pThis%) :"_BS_ISteamGameServer_ClearAllKeyValues@4"
+BS_ISteamGameServer_SetKeyValue(pThis%, cKey$, cValue$) :"_BS_ISteamGameServer_SetKeyValue@12"
+BS_ISteamGameServer_SetGameTags(pThis%, cTags$) :"_BS_ISteamGameServer_SetGameTags@8"
+BS_ISteamGameServer_SetGameData(pThis%, cData$) :"_BS_ISteamGameServer_SetGameData@8"
+BS_ISteamGameServer_SetRegion(pThis%, cRegion$) :"_BS_ISteamGameServer_SetRegion@8"
+BS_ISteamGameServer_SendUserConnectAndAuthenticate%(pThis%, iIP%, pAuthBlob*, iAuthBlobSize%, lSteamId%):"_BS_ISteamGameServer_SendUserConnectAndAuthenticate@20"
+BS_ISteamGameServer_SendUserConnectAndAuthenticateEx%(pThis%, iIP%, pAuthBlob%, iAuthBlobSize%, lSteamId%):"_BS_ISteamGameServer_SendUserConnectAndAuthenticate@20"
+BS_ISteamGameServer_CreateUnauthenticatedUserConnection%(pThis%) :"_BS_ISteamGameServer_CreateUnauthenticatedUserConnection@4"
+;! Function above returns a CSteamID*, clean it up afterwards!
+BS_ISteamGameServer_SendUserDisconnect(pThis%, lSteamId%) :"_BS_ISteamGameServer_SendUserDisconnect@8"
+BS_ISteamGameServer_UpdateUserData%(pThis%, lSteamId%, cName$, iScore%):"_BS_ISteamGameServer_UpdateUserData@16"
+BS_ISteamGameServer_GetAuthSessionTicket%(pThis%, pTicket*, iTicketSize%, piTicketSize*):"_BS_ISteamGameServer_GetAuthSessionTicket@16"
+BS_ISteamGameServer_GetAuthSessionTicketEx%(pThis%, pTicket%, iTicketSize%, piTicketSize%):"_BS_ISteamGameServer_GetAuthSessionTicket@16"
+BS_ISteamGameServer_BeginAuthSession%(pThis%, pTicket*, iTicketSize%, lSteamId%):"_BS_ISteamGameServer_BeginAuthSession@16"
+BS_ISteamGameServer_BeginAuthSessionEx%(pThis%, pTicket%, iTicketSize%, lSteamId%):"_BS_ISteamGameServer_BeginAuthSession@16"
+BS_ISteamGameServer_EndAuthSession(pThis%, lSteamId%) :"_BS_ISteamGameServer_EndAuthSession@8"
+BS_ISteamGameServer_CancelAuthTicket(pThis%, iAuthTicket%) :"_BS_ISteamGameServer_CancelAuthTicket@8"
+BS_ISteamGameServer_UserHasLicenseForApp%(pThis%, lSteamId%, iAppId%) :"_BS_ISteamGameServer_UserHasLicenseForApp@12"
+BS_ISteamGameServer_RequestUserGroupStatus%(pThis%, lSteamId%, pSteamIdGroup%) :"_BS_ISteamGameServer_RequestUserGroupStatus@12"
+BS_ISteamGameServer_GetPublicIP%(pThis%) :"_BS_ISteamGameServer_GetPublicIP@4"
+BS_ISteamGameServer_HandleIncomingPacket%(pThis%, pBuffer*, iBufferSize%, iIP%, sPort%):"_BS_ISteamGameServer_HandleIncomingPacket@20"
+BS_ISteamGameServer_HandleIncomingPacketEx%(pThis%, pBuffer%, iBufferSize%, iIP%, sPort%):"_BS_ISteamGameServer_HandleIncomingPacket@20"
+BS_ISteamGameServer_GetNextOutgoingPacket%(pThis%, pBuffer*, iBufferSize%, piIP*, psPort*):"_BS_ISteamGameServer_GetNextOutgoingPacket@20"
+BS_ISteamGameServer_GetNextOutgoingPacketEx%(pThis%, pBuffer%, iBufferSize%, piIP%, psPort%):"_BS_ISteamGameServer_GetNextOutgoingPacket@20"
+BS_ISteamGameServer_EnableHeartbeats(pThis%, bActive%) :"_BS_ISteamGameServer_EnableHeartbeats@8"
+BS_ISteamGameServer_SetHeartbeatInterval(pThis%, iInterval%) :"_BS_ISteamGameServer_SetHeartbeatInterval@8"
+BS_ISteamGameServer_ForceHeartbeat(pThis%) :"_BS_ISteamGameServer_ForceHeartbeat@4"
+BS_ISteamGameServer_AssociateWithClan%(pThis%, pSteamIDClan%) :"_BS_ISteamGameServer_AssociateWithClan@8"
+;! Function above returns a SteamAPICall_t*, clean it up afterwards!
+BS_ISteamGameServer_ComputeNewPlayerCompatibility%(pThis%, pSteamIDNewPlayer%) :"_BS_ISteamGameServer_ComputeNewPlayerCompatibility@8"
+;! Function above returns a SteamAPICall_t*, clean it up afterwards!
diff --git a/Resources/Decls/BlitzSteam_SteamGameServerStats.decls b/Resources/Decls/BlitzSteam_SteamGameServerStats.decls
index f99fd57..61241d1 100644
--- a/Resources/Decls/BlitzSteam_SteamGameServerStats.decls
+++ b/Resources/Decls/BlitzSteam_SteamGameServerStats.decls
@@ -1,36 +1,36 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; GameServerStats -------------------------------------------------------------
-BS_SteamGameServerStats%() :"_BS_SteamGameServerStats@0"
-BS_ISteamGameServerStats_RequestUserStats%(pThis%, lSteamId%) :"_BS_ISteamGameServerStats_RequestUserStats@8"
-;! Function above returns a SteamAPICall_t*, clean it up afterwards!
-BS_ISteamGameServerStats_StoreUserStats%(pThis%, lSteamId%) :"_BS_ISteamGameServerStats_StoreUserStats@8"
-;! Function above returns a SteamAPICall_t*, clean it up afterwards!
-BS_ISteamGameServerStats_GetUserStat%(pThis%, lSteamId%, cName$, pData*) :"_BS_ISteamGameServerStats_GetUserStat@16"
-BS_ISteamGameServerStats_GetUserStatEx%(pThis%, lSteamId%, cName$, pData%) :"_BS_ISteamGameServerStats_GetUserStat@16"
-BS_ISteamGameServerStats_GetUserStatF%(pThis%, lSteamId%, cName$, pData*) :"_BS_ISteamGameServerStats_GetUserStatF@16"
-BS_ISteamGameServerStats_GetUserStatFEx%(pThis%, lSteamId%, cName$, pData%) :"_BS_ISteamGameServerStats_GetUserStatF@16"
-BS_ISteamGameServerStats_GetUserAchievement%(pThis%, lSteamId%, cName$, pbAchieved*):"_BS_ISteamGameServerStats_GetUserAchievement@16"
-BS_ISteamGameServerStats_GetUserAchievementEx%(pThis%, lSteamId%, cName$, pbAchieved%):"_BS_ISteamGameServerStats_GetUserAchievement@16"
-BS_ISteamGameServerStats_SetUserStat%(pThis%, lSteamId%, cName%, iData%) :"_BS_ISteamGameServerStats_SetUserStat@16"
-BS_ISteamGameServerStats_SetUserStatF%(pThis%, lSteamId%, cName%, fData#) :"_BS_ISteamGameServerStats_SetUserStatF@16"
-BS_ISteamGameServerStats_UpdateUserAvgRateStat%(pThis%, lSteamId%, cName$, fCountThisSession#, dSessionLength%):"_BS_ISteamGameServerStats_UpdateUserAvgRateStat@20"
-;! Function above takes a Double* as last parameter.
-BS_ISteamGameServerStats_SetUserAchievement%(pThis%, lSteamId%, cName$) :"_BS_ISteamGameServerStats_SetUserAchievement@12"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; GameServerStats -------------------------------------------------------------
+BS_SteamGameServerStats%() :"_BS_SteamGameServerStats@0"
+BS_ISteamGameServerStats_RequestUserStats%(pThis%, lSteamId%) :"_BS_ISteamGameServerStats_RequestUserStats@8"
+;! Function above returns a SteamAPICall_t*, clean it up afterwards!
+BS_ISteamGameServerStats_StoreUserStats%(pThis%, lSteamId%) :"_BS_ISteamGameServerStats_StoreUserStats@8"
+;! Function above returns a SteamAPICall_t*, clean it up afterwards!
+BS_ISteamGameServerStats_GetUserStat%(pThis%, lSteamId%, cName$, pData*) :"_BS_ISteamGameServerStats_GetUserStat@16"
+BS_ISteamGameServerStats_GetUserStatEx%(pThis%, lSteamId%, cName$, pData%) :"_BS_ISteamGameServerStats_GetUserStat@16"
+BS_ISteamGameServerStats_GetUserStatF%(pThis%, lSteamId%, cName$, pData*) :"_BS_ISteamGameServerStats_GetUserStatF@16"
+BS_ISteamGameServerStats_GetUserStatFEx%(pThis%, lSteamId%, cName$, pData%) :"_BS_ISteamGameServerStats_GetUserStatF@16"
+BS_ISteamGameServerStats_GetUserAchievement%(pThis%, lSteamId%, cName$, pbAchieved*):"_BS_ISteamGameServerStats_GetUserAchievement@16"
+BS_ISteamGameServerStats_GetUserAchievementEx%(pThis%, lSteamId%, cName$, pbAchieved%):"_BS_ISteamGameServerStats_GetUserAchievement@16"
+BS_ISteamGameServerStats_SetUserStat%(pThis%, lSteamId%, cName%, iData%) :"_BS_ISteamGameServerStats_SetUserStat@16"
+BS_ISteamGameServerStats_SetUserStatF%(pThis%, lSteamId%, cName%, fData#) :"_BS_ISteamGameServerStats_SetUserStatF@16"
+BS_ISteamGameServerStats_UpdateUserAvgRateStat%(pThis%, lSteamId%, cName$, fCountThisSession#, dSessionLength%):"_BS_ISteamGameServerStats_UpdateUserAvgRateStat@20"
+;! Function above takes a Double* as last parameter.
+BS_ISteamGameServerStats_SetUserAchievement%(pThis%, lSteamId%, cName$) :"_BS_ISteamGameServerStats_SetUserAchievement@12"
BS_ISteamGameServerStats_ClearUserAchievement%(pThis%, lSteamId%, cName$) :"_BS_ISteamGameServerStats_ClearUserAchievement@12"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamHTMLSurface.decls b/Resources/Decls/BlitzSteam_SteamHTMLSurface.decls
index dfc6bfe..9e4dee5 100644
--- a/Resources/Decls/BlitzSteam_SteamHTMLSurface.decls
+++ b/Resources/Decls/BlitzSteam_SteamHTMLSurface.decls
@@ -1,56 +1,56 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; HTMLSurface -----------------------------------------------------------------
-BS_SteamHTMLSurface%() :"_BS_SteamHTMLSurface@0"
-BS_ISteamHTMLSurface_Init%(pThis%) :"_BS_ISteamHTMLSurface_Init@4"
-BS_ISteamHTMLSurface_Shutdown%(pThis%) :"_BS_ISteamHTMLSurface_Shutdown@4"
-BS_ISteamHTMLSurface_CreateBrowser%(pThis%, cUserAgent$, cUserCSS$) :"_BS_ISteamHTMLSurface_CreateBrowser@12"
-;! Function above returns a SteamAPICall_t*, clean it up afterwards!
-BS_ISteamHTMLSurface_RemoveBrowser(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_RemoveBrowser@8"
-BS_ISteamHTMLSurface_LoadURL(pThis%, iHandle%, cURL$, cPostData$) :"_BS_ISteamHTMLSurface_LoadURL@16"
-BS_ISteamHTMLSurface_SetSize(pThis%, iHandle%, iWidth%, iHeight%) :"_BS_ISteamHTMLSurface_SetSize@16"
-BS_ISteamHTMLSurface_StopLoad(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_StopLoad@8"
-BS_ISteamHTMLSurface_Reload(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_Reload@8"
-BS_ISteamHTMLSurface_GoBack(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_GoBack@8"
-BS_ISteamHTMLSurface_GoForward(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_GoForward@8"
-BS_ISteamHTMLSurface_AddHeader(pThis%, iHandle%, cKey$, cValue$) :"_BS_ISteamHTMLSurface_AddHeader@16"
-BS_ISteamHTMLSurface_ExecuteJavascript(pThis%, iHandle%, cScript$) :"_BS_ISteamHTMLSurface_ExecuteJavascript@12"
-BS_ISteamHTMLSurface_MouseUp(pThis%, iHandle%, EMouseButton%) :"_BS_ISteamHTMLSurface_MouseUp@12"
-BS_ISteamHTMLSurface_MouseDown(pThis%, iHandle%, EMouseButton%) :"_BS_ISteamHTMLSurface_MouseDown@12"
-BS_ISteamHTMLSurface_MouseDoubleClick(pThis%, iHandle%, EMouseButton%) :"_BS_ISteamHTMLSurface_MouseDoubleClick@12"
-BS_ISteamHTMLSurface_MouseMove(pThis%, iHandle%, X%, Y%) :"_BS_ISteamHTMLSurface_MouseMove@16"
-BS_ISteamHTMLSurface_MouseWheel(pThis%, iHandle%, iDelta%) :"_BS_ISteamHTMLSurface_MouseWheel@12"
-BS_ISteamHTMLSurface_KeyDown(pThis%, iHandle%, iKeyCode%, EHTMLKeyModifiers%) :"_BS_ISteamHTMLSurface_KeyDown@16"
-BS_ISteamHTMLSurface_KeyUp(pThis%, iHandle%, iKeyCode%, EHTMLKeyModifiers%) :"_BS_ISteamHTMLSurface_KeyUp@16"
-BS_ISteamHTMLSurface_KeyChar(pThis%, iHandle%, iUnicodeChar%, EHTMLKeyModifiers%):"_BS_ISteamHTMLSurface_KeyChar@16"
-BS_ISteamHTMLSurface_SetHorizontalScroll(pThis%, iHandle%, iAbsolutePixelScroll%):"_BS_ISteamHTMLSurface_SetHorizontalScroll@16"
-BS_ISteamHTMLSurface_SetVerticalScroll(pThis%, iHandle%, iAbsolutePixelScroll%) :"_BS_ISteamHTMLSurface_SetVerticalScroll@16"
-BS_ISteamHTMLSurface_SetKeyFocus(pThis%, iHandle%, bHasKeyFocus%) :"_BS_ISteamHTMLSurface_SetKeyFocus@12"
-BS_ISteamHTMLSurface_ViewSource(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_ViewSource@8"
-BS_ISteamHTMLSurface_CopyToClipboard(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_CopyToClipboard@8"
-BS_ISteamHTMLSurface_PasteFromClipboard(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_PasteFromClipboard@8"
-BS_ISteamHTMLSurface_Find(pThis%, iHandle%, cSearch$, bCurrentlyInFind%, bReverse%):"_BS_ISteamHTMLSurface_Find@20"
-BS_ISteamHTMLSurface_StopFind(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_StopFind@8"
-BS_ISteamHTMLSurface_GetLinkAtPosition(pThis%, iHandle%, X%, Y%) :"_BS_ISteamHTMLSurface_GetLinkAtPosition@16"
-BS_ISteamHTMLSurface_SetCookie(pThis%, iHandle%, cHostName$, cKey$, cValue$, cPath$, nExpires%, bSecure%, bHTTPOnly%):"_BS_ISteamHTMLSurface_SetCookie@36"
-BS_ISteamHTMLSurface_SetPageScaleFactor(pThis%, iHandle%, fZoom#, iX%, iY%) :"_BS_ISteamHTMLSurface_SetPageScaleFactor@20"
-BS_ISteamHTMLSurface_SetBackgroundMode(pThis%, iHandle%, bBackgroundMode%) :"_BS_ISteamHTMLSurface_SetBackgroundMode@12"
-BS_ISteamHTMLSurface_AllowStartRequest(pThis%, iHandle%, bAllowed%) :"_BS_ISteamHTMLSurface_AllowStartRequest@12"
-BS_ISteamHTMLSurface_JSDialogResponse(pThis%, iHandle%, bResult%) :"_BS_ISteamHTMLSurface_JSDialogResponse@12"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; HTMLSurface -----------------------------------------------------------------
+BS_SteamHTMLSurface%() :"_BS_SteamHTMLSurface@0"
+BS_ISteamHTMLSurface_Init%(pThis%) :"_BS_ISteamHTMLSurface_Init@4"
+BS_ISteamHTMLSurface_Shutdown%(pThis%) :"_BS_ISteamHTMLSurface_Shutdown@4"
+BS_ISteamHTMLSurface_CreateBrowser%(pThis%, cUserAgent$, cUserCSS$) :"_BS_ISteamHTMLSurface_CreateBrowser@12"
+;! Function above returns a SteamAPICall_t*, clean it up afterwards!
+BS_ISteamHTMLSurface_RemoveBrowser(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_RemoveBrowser@8"
+BS_ISteamHTMLSurface_LoadURL(pThis%, iHandle%, cURL$, cPostData$) :"_BS_ISteamHTMLSurface_LoadURL@16"
+BS_ISteamHTMLSurface_SetSize(pThis%, iHandle%, iWidth%, iHeight%) :"_BS_ISteamHTMLSurface_SetSize@16"
+BS_ISteamHTMLSurface_StopLoad(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_StopLoad@8"
+BS_ISteamHTMLSurface_Reload(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_Reload@8"
+BS_ISteamHTMLSurface_GoBack(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_GoBack@8"
+BS_ISteamHTMLSurface_GoForward(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_GoForward@8"
+BS_ISteamHTMLSurface_AddHeader(pThis%, iHandle%, cKey$, cValue$) :"_BS_ISteamHTMLSurface_AddHeader@16"
+BS_ISteamHTMLSurface_ExecuteJavascript(pThis%, iHandle%, cScript$) :"_BS_ISteamHTMLSurface_ExecuteJavascript@12"
+BS_ISteamHTMLSurface_MouseUp(pThis%, iHandle%, EMouseButton%) :"_BS_ISteamHTMLSurface_MouseUp@12"
+BS_ISteamHTMLSurface_MouseDown(pThis%, iHandle%, EMouseButton%) :"_BS_ISteamHTMLSurface_MouseDown@12"
+BS_ISteamHTMLSurface_MouseDoubleClick(pThis%, iHandle%, EMouseButton%) :"_BS_ISteamHTMLSurface_MouseDoubleClick@12"
+BS_ISteamHTMLSurface_MouseMove(pThis%, iHandle%, X%, Y%) :"_BS_ISteamHTMLSurface_MouseMove@16"
+BS_ISteamHTMLSurface_MouseWheel(pThis%, iHandle%, iDelta%) :"_BS_ISteamHTMLSurface_MouseWheel@12"
+BS_ISteamHTMLSurface_KeyDown(pThis%, iHandle%, iKeyCode%, EHTMLKeyModifiers%) :"_BS_ISteamHTMLSurface_KeyDown@16"
+BS_ISteamHTMLSurface_KeyUp(pThis%, iHandle%, iKeyCode%, EHTMLKeyModifiers%) :"_BS_ISteamHTMLSurface_KeyUp@16"
+BS_ISteamHTMLSurface_KeyChar(pThis%, iHandle%, iUnicodeChar%, EHTMLKeyModifiers%):"_BS_ISteamHTMLSurface_KeyChar@16"
+BS_ISteamHTMLSurface_SetHorizontalScroll(pThis%, iHandle%, iAbsolutePixelScroll%):"_BS_ISteamHTMLSurface_SetHorizontalScroll@16"
+BS_ISteamHTMLSurface_SetVerticalScroll(pThis%, iHandle%, iAbsolutePixelScroll%) :"_BS_ISteamHTMLSurface_SetVerticalScroll@16"
+BS_ISteamHTMLSurface_SetKeyFocus(pThis%, iHandle%, bHasKeyFocus%) :"_BS_ISteamHTMLSurface_SetKeyFocus@12"
+BS_ISteamHTMLSurface_ViewSource(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_ViewSource@8"
+BS_ISteamHTMLSurface_CopyToClipboard(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_CopyToClipboard@8"
+BS_ISteamHTMLSurface_PasteFromClipboard(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_PasteFromClipboard@8"
+BS_ISteamHTMLSurface_Find(pThis%, iHandle%, cSearch$, bCurrentlyInFind%, bReverse%):"_BS_ISteamHTMLSurface_Find@20"
+BS_ISteamHTMLSurface_StopFind(pThis%, iHandle%) :"_BS_ISteamHTMLSurface_StopFind@8"
+BS_ISteamHTMLSurface_GetLinkAtPosition(pThis%, iHandle%, X%, Y%) :"_BS_ISteamHTMLSurface_GetLinkAtPosition@16"
+BS_ISteamHTMLSurface_SetCookie(pThis%, iHandle%, cHostName$, cKey$, cValue$, cPath$, nExpires%, bSecure%, bHTTPOnly%):"_BS_ISteamHTMLSurface_SetCookie@36"
+BS_ISteamHTMLSurface_SetPageScaleFactor(pThis%, iHandle%, fZoom#, iX%, iY%) :"_BS_ISteamHTMLSurface_SetPageScaleFactor@20"
+BS_ISteamHTMLSurface_SetBackgroundMode(pThis%, iHandle%, bBackgroundMode%) :"_BS_ISteamHTMLSurface_SetBackgroundMode@12"
+BS_ISteamHTMLSurface_AllowStartRequest(pThis%, iHandle%, bAllowed%) :"_BS_ISteamHTMLSurface_AllowStartRequest@12"
+BS_ISteamHTMLSurface_JSDialogResponse(pThis%, iHandle%, bResult%) :"_BS_ISteamHTMLSurface_JSDialogResponse@12"
BS_ISteamHTMLSurface_FileLoadDialogResponse(pThis%, iHandle%, pcSelectedFiles%) :"_BS_ISteamHTMLSurface_FileLoadDialogResponse@12"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamHTTP.decls b/Resources/Decls/BlitzSteam_SteamHTTP.decls
index 45a819a..e51d1df 100644
--- a/Resources/Decls/BlitzSteam_SteamHTTP.decls
+++ b/Resources/Decls/BlitzSteam_SteamHTTP.decls
@@ -1,54 +1,54 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; HTTP ------------------------------------------------------------------------
-BS_SteamHTTP%() :"_BS_SteamHTTP@0"
-BS_SteamGameServerHTTP%() :"_BS_SteamGameServerHTTP@0"
-BS_ISteamHTTP_CreateHTTPRequest%(pThis%, EHTTPRequestMethod%, cAbsoluteUrl$) :"_BS_ISteamHTTP_CreateHTTPRequest@12"
-BS_ISteamHTTP_SetHTTPRequestContextValue%(pThis%, iRequest%, lContextValue%) :"_BS_ISteamHTTP_SetHTTPRequestContextValue@12"
-BS_ISteamHTTP_SetHTTPNetworkActivityTimeout%(pThis%, iRequest%, iSeconds%) :"_BS_ISteamHTTP_SetHTTPNetworkActivityTimeout@12"
-BS_ISteamHTTP_SetHTTPRequestHeaderValue%(pThis%, iRequest%, cName$, cValue$) :"_BS_ISteamHTTP_SetHTTPRequestHeaderValue@16"
-BS_ISteamHTTP_SetHTTPRequestGetOrPostParameter%(pThis%, iRequest%, cName$, cValue$):"_BS_ISteamHTTP_SetHTTPRequestGetOrPostParameter@16"
-BS_ISteamHTTP_SendHTTPRequest%(pThis%, iRequest, lCallHandle%) :"_BS_ISteamHTTP_SendHTTPRequest@12"
-BS_ISteamHTTP_SendHTTPRequestAndStreamResponse%(pThis%, iRequest%, lCallHandle%):"_BS_ISteamHTTP_SendHTTPRequestAndStreamResponse@12"
-BS_ISteamHTTP_DeferHTTPRequest%(pThis%, iRequest%) :"_BS_ISteamHTTP_DeferHTTPRequest@8"
-BS_ISteamHTTP_PrioritizeHTTPRequest%(pThis%, iRequest%) :"_BS_ISteamHTTP_PrioritizeHTTPRequest@8"
-BS_ISteamHTTP_GetHTTPResponseHeaderSize%(pThis%, iRequest%, cName$, piSize*) :"_BS_ISteamHTTP_GetHTTPResponseHeaderSize@16"
-BS_ISteamHTTP_GetHTTPResponseHeaderSizeEx%(pThis%, iRequest%, cName$, piSize%) :"_BS_ISteamHTTP_GetHTTPResponseHeaderSize@16"
-BS_ISteamHTTP_GetHTTPResponseHeaderValue%(pThis%, iRequest%, cName$, pBuffer*, iSize%):"_BS_ISteamHTTP_GetHTTPResponseHeaderValue@20"
-BS_ISteamHTTP_GetHTTPResponseHeaderValueEx%(pThis%, iRequest%, cName$, pBuffer%, iSize%):"_BS_ISteamHTTP_GetHTTPResponseHeaderValue@20"
-BS_ISteamHTTP_GetHTTPResponseBodySize%(pThis%, iRequest%, piSize*) :"_BS_ISteamHTTP_GetHTTPResponseBodySize@12"
-BS_ISteamHTTP_GetHTTPResponseBodySizeEx%(pThis%, iRequest%, piSize%) :"_BS_ISteamHTTP_GetHTTPResponseBodySize@12"
-BS_ISteamHTTP_GetHTTPResponseBodyData%(pThis%, iRequest%, pBuffer*, nSize%) :"_BS_ISteamHTTP_GetHTTPResponseBodyData@16"
-BS_ISteamHTTP_GetHTTPResponseBodyDataEx%(pThis%, iRequest%, pBuffer%, nSize%) :"_BS_ISteamHTTP_GetHTTPResponseBodyData@16"
-BS_ISteamHTTP_GetHTTPStreamingResponseBodyData%(pThis%, iRequest%, iOffset%, pBuffer*, nSize%):"_BS_ISteamHTTP_GetHTTPStreamingResponseBodyData@20"
-BS_ISteamHTTP_GetHTTPStreamingResponseBodyDataEx%(pThis%, iRequest%, iOffset%, pBuffer%, nSize%):"_BS_ISteamHTTP_GetHTTPStreamingResponseBodyData@20"
-BS_ISteamHTTP_ReleaseHTTPRequest%(pThis%, iRequest%) :"_BS_ISteamHTTP_ReleaseHTTPRequest@8"
-BS_ISteamHTTP_GetHTTPDownloadProgressPct%(pThis%, iRequest%, pfPercent*) :"_BS_ISteamHTTP_GetHTTPDownloadProgressPct@12"
-BS_ISteamHTTP_GetHTTPDownloadProgressPctEx%(pThis%, iRequest%, pfPercent%) :"_BS_ISteamHTTP_GetHTTPDownloadProgressPct@12"
-BS_ISteamHTTP_SetHTTPRequestRawPostBody%(pThis%, iRequest%, cType$, pBody*, nSize%):"_BS_ISteamHTTP_SetHTTPRequestRawPostBody@16"
-BS_ISteamHTTP_SetHTTPRequestRawPostBodyEx%(pThis%, iRequest%, cType$, pBody*, nSize%):"_BS_ISteamHTTP_SetHTTPRequestRawPostBody@16"
-BS_ISteamHTTP_CreateCookieContainer%(pThis%, bAllowResponsesToModify%) :"_BS_ISteamHTTP_CreateCookieContainer@8"
-BS_ISteamHTTP_ReleaseCookieContainer%(pThis%, iCookieContainer%) :"_BS_ISteamHTTP_ReleaseCookieContainer@8"
-BS_ISteamHTTP_SetCookie%(pthis%, iCookieContainer%, cHost$, cUrl$, cCookie$) :"_BS_ISteamHTTP_SetCookie@20"
-BS_ISteamHTTP_SetHTTPRequestCookieContainer%(pThis%, iRequest%, iCookieContainer%):"_BS_ISteamHTTP_SetHTTPRequestCookieContainer@12"
-BS_ISteamHTTP_SetHTTPRequestUserAgentInfo%(pThis%, iRequest%, cUserAgent$) :"_BS_ISteamHTTP_SetHTTPRequestUserAgentInfo@12"
-BS_ISteamHTTP_SetHTTPRequestRequiresVerifiedCertificate%(pThis%, iRequest%, bRequire%):"_BS_ISteamHTTP_SetHTTPRequestRequiresVerifiedCertificate@12"
-BS_ISteamHTTP_SetHTTPRequestAbsoluteTimeoutMS%(pThis%, iRequest%, iMilliseconds%):"_BS_ISteamHTTP_SetHTTPRequestAbsoluteTimeoutMS@12"
-BS_ISteamHTTP_GetHTTPRequestWasTimedOut%(pThis%, iRequest%, pbWasTimedOut*) :"_BS_ISteamHTTP_GetHTTPRequestWasTimedOut@12"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; HTTP ------------------------------------------------------------------------
+BS_SteamHTTP%() :"_BS_SteamHTTP@0"
+BS_SteamGameServerHTTP%() :"_BS_SteamGameServerHTTP@0"
+BS_ISteamHTTP_CreateHTTPRequest%(pThis%, EHTTPRequestMethod%, cAbsoluteUrl$) :"_BS_ISteamHTTP_CreateHTTPRequest@12"
+BS_ISteamHTTP_SetHTTPRequestContextValue%(pThis%, iRequest%, lContextValue%) :"_BS_ISteamHTTP_SetHTTPRequestContextValue@12"
+BS_ISteamHTTP_SetHTTPNetworkActivityTimeout%(pThis%, iRequest%, iSeconds%) :"_BS_ISteamHTTP_SetHTTPNetworkActivityTimeout@12"
+BS_ISteamHTTP_SetHTTPRequestHeaderValue%(pThis%, iRequest%, cName$, cValue$) :"_BS_ISteamHTTP_SetHTTPRequestHeaderValue@16"
+BS_ISteamHTTP_SetHTTPRequestGetOrPostParameter%(pThis%, iRequest%, cName$, cValue$):"_BS_ISteamHTTP_SetHTTPRequestGetOrPostParameter@16"
+BS_ISteamHTTP_SendHTTPRequest%(pThis%, iRequest, lCallHandle%) :"_BS_ISteamHTTP_SendHTTPRequest@12"
+BS_ISteamHTTP_SendHTTPRequestAndStreamResponse%(pThis%, iRequest%, lCallHandle%):"_BS_ISteamHTTP_SendHTTPRequestAndStreamResponse@12"
+BS_ISteamHTTP_DeferHTTPRequest%(pThis%, iRequest%) :"_BS_ISteamHTTP_DeferHTTPRequest@8"
+BS_ISteamHTTP_PrioritizeHTTPRequest%(pThis%, iRequest%) :"_BS_ISteamHTTP_PrioritizeHTTPRequest@8"
+BS_ISteamHTTP_GetHTTPResponseHeaderSize%(pThis%, iRequest%, cName$, piSize*) :"_BS_ISteamHTTP_GetHTTPResponseHeaderSize@16"
+BS_ISteamHTTP_GetHTTPResponseHeaderSizeEx%(pThis%, iRequest%, cName$, piSize%) :"_BS_ISteamHTTP_GetHTTPResponseHeaderSize@16"
+BS_ISteamHTTP_GetHTTPResponseHeaderValue%(pThis%, iRequest%, cName$, pBuffer*, iSize%):"_BS_ISteamHTTP_GetHTTPResponseHeaderValue@20"
+BS_ISteamHTTP_GetHTTPResponseHeaderValueEx%(pThis%, iRequest%, cName$, pBuffer%, iSize%):"_BS_ISteamHTTP_GetHTTPResponseHeaderValue@20"
+BS_ISteamHTTP_GetHTTPResponseBodySize%(pThis%, iRequest%, piSize*) :"_BS_ISteamHTTP_GetHTTPResponseBodySize@12"
+BS_ISteamHTTP_GetHTTPResponseBodySizeEx%(pThis%, iRequest%, piSize%) :"_BS_ISteamHTTP_GetHTTPResponseBodySize@12"
+BS_ISteamHTTP_GetHTTPResponseBodyData%(pThis%, iRequest%, pBuffer*, nSize%) :"_BS_ISteamHTTP_GetHTTPResponseBodyData@16"
+BS_ISteamHTTP_GetHTTPResponseBodyDataEx%(pThis%, iRequest%, pBuffer%, nSize%) :"_BS_ISteamHTTP_GetHTTPResponseBodyData@16"
+BS_ISteamHTTP_GetHTTPStreamingResponseBodyData%(pThis%, iRequest%, iOffset%, pBuffer*, nSize%):"_BS_ISteamHTTP_GetHTTPStreamingResponseBodyData@20"
+BS_ISteamHTTP_GetHTTPStreamingResponseBodyDataEx%(pThis%, iRequest%, iOffset%, pBuffer%, nSize%):"_BS_ISteamHTTP_GetHTTPStreamingResponseBodyData@20"
+BS_ISteamHTTP_ReleaseHTTPRequest%(pThis%, iRequest%) :"_BS_ISteamHTTP_ReleaseHTTPRequest@8"
+BS_ISteamHTTP_GetHTTPDownloadProgressPct%(pThis%, iRequest%, pfPercent*) :"_BS_ISteamHTTP_GetHTTPDownloadProgressPct@12"
+BS_ISteamHTTP_GetHTTPDownloadProgressPctEx%(pThis%, iRequest%, pfPercent%) :"_BS_ISteamHTTP_GetHTTPDownloadProgressPct@12"
+BS_ISteamHTTP_SetHTTPRequestRawPostBody%(pThis%, iRequest%, cType$, pBody*, nSize%):"_BS_ISteamHTTP_SetHTTPRequestRawPostBody@16"
+BS_ISteamHTTP_SetHTTPRequestRawPostBodyEx%(pThis%, iRequest%, cType$, pBody*, nSize%):"_BS_ISteamHTTP_SetHTTPRequestRawPostBody@16"
+BS_ISteamHTTP_CreateCookieContainer%(pThis%, bAllowResponsesToModify%) :"_BS_ISteamHTTP_CreateCookieContainer@8"
+BS_ISteamHTTP_ReleaseCookieContainer%(pThis%, iCookieContainer%) :"_BS_ISteamHTTP_ReleaseCookieContainer@8"
+BS_ISteamHTTP_SetCookie%(pthis%, iCookieContainer%, cHost$, cUrl$, cCookie$) :"_BS_ISteamHTTP_SetCookie@20"
+BS_ISteamHTTP_SetHTTPRequestCookieContainer%(pThis%, iRequest%, iCookieContainer%):"_BS_ISteamHTTP_SetHTTPRequestCookieContainer@12"
+BS_ISteamHTTP_SetHTTPRequestUserAgentInfo%(pThis%, iRequest%, cUserAgent$) :"_BS_ISteamHTTP_SetHTTPRequestUserAgentInfo@12"
+BS_ISteamHTTP_SetHTTPRequestRequiresVerifiedCertificate%(pThis%, iRequest%, bRequire%):"_BS_ISteamHTTP_SetHTTPRequestRequiresVerifiedCertificate@12"
+BS_ISteamHTTP_SetHTTPRequestAbsoluteTimeoutMS%(pThis%, iRequest%, iMilliseconds%):"_BS_ISteamHTTP_SetHTTPRequestAbsoluteTimeoutMS@12"
+BS_ISteamHTTP_GetHTTPRequestWasTimedOut%(pThis%, iRequest%, pbWasTimedOut*) :"_BS_ISteamHTTP_GetHTTPRequestWasTimedOut@12"
BS_ISteamHTTP_GetHTTPRequestWasTimedOutEx%(pThis%, iRequest%, pbWasTimedOut%) :"_BS_ISteamHTTP_GetHTTPRequestWasTimedOut@12"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamInventory.decls b/Resources/Decls/BlitzSteam_SteamInventory.decls
index 732f2dd..adb6819 100644
--- a/Resources/Decls/BlitzSteam_SteamInventory.decls
+++ b/Resources/Decls/BlitzSteam_SteamInventory.decls
@@ -1,59 +1,59 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; Inventory -------------------------------------------------------------------
-BS_SteamInventory%() :"_BS_SteamInventory@0"
-BS_SteamGameServerInventory%() :"_BS_SteamGameServerInventory@0"
-BS_ISteamInventory_GetResultStatus%(pThis%, iResultHandle%) :"_BS_ISteamInventory_GetResultStatus@8"
-BS_ISteamInventory_GetResultItems%(pThis%, iResultHandle%, pItemsArray*, piItemsArraySize*):"_BS_ISteamInventory_GetResultItems@16"
-BS_ISteamInventory_GetResultItemsEx%(pThis%, iResultHandle%, pItemsArray%, piItemsArraySize%):"_BS_ISteamInventory_GetResultItems@16"
-BS_ISteamInventory_GetResultTimestamp%(pThis%, iResultHandle%) :"_BS_ISteamInventory_GetResultTimestamp@8"
-BS_ISteamInventory_CheckResultSteamID%(pThis%, iResultHandle%, lSteamIdExpected%):"_BS_ISteamInventory_GetResultTimestamp@12"
-BS_ISteamInventory_DestroyResult(pThis%, iResultHandle%) :"_BS_ISteamInventory_DestroyResult@8"
-BS_ISteamInventory_GetAllItems%(pThis%, piResultHandle*) :"_BS_ISteamInventory_GetAllItems@8"
-BS_ISteamInventory_GetAllItemsEx%(pThis%, piResultHandle%) :"_BS_ISteamInventory_GetAllItems@8"
-BS_ISteamInventory_GetItemsByID%(pThis%, piResultHandle*, plInstanceIds*, iInstanceIdCount%):"_BS_ISteamInventory_GetItemsByID@16"
-BS_ISteamInventory_GetItemsByIDEx%(pThis%, piResultHandle%, plInstanceIds%, iInstanceIdCount%):"_BS_ISteamInventory_GetItemsByID@16"
-BS_ISteamInventory_SerializeResult%(pThis%, iResultHandle%, pOutBuffer*, piOutBufferSize*):"_BS_ISteamInventory_SerializeResult@16"
-BS_ISteamInventory_SerializeResultEx%(pThis%, iResultHandle%, pOutBuffer%, piOutBufferSize%):"_BS_ISteamInventory_SerializeResult@16"
-BS_ISteamInventory_DeserializeResult%(pThis%, piResultHandle*, pBuffer*, iBufferSize%, bReservedMustBeFalse):"_BS_ISteamInventory_DeserializeResult@20"
-BS_ISteamInventory_DeserializeResultEx%(pThis%, piResultHandle%, pBuffer%, iBufferSize%, bReservedMustBeFalse):"_BS_ISteamInventory_DeserializeResult@20"
-BS_ISteamInventory_GenerateItems%(pThis%, piResultHandle*, piIdArray*, piQuantityArray*, iArrayLength%):"_BS_ISteamInventory_GenerateItems@20"
-BS_ISteamInventory_GenerateItemsEx%(pThis%, piResultHandle%, piIdArray%, piQuantityArray%, iArrayLength%):"_BS_ISteamInventory_GenerateItems@20"
-BS_ISteamInventory_GrantPromoItems%(pThis%, piResultHandle*) :"_BS_ISteamInventory_GrantPromoItems@8"
-BS_ISteamInventory_GrantPromoItemsEx%(pThis%, piResultHandle%) :"_BS_ISteamInventory_GrantPromoItems@8"
-BS_ISteamInventory_AddPromoItem%(pThis%, piResultHandle*, iId%) :"_BS_ISteamInventory_AddPromoItem@12"
-BS_ISteamInventory_AddPromoItemEx%(pThis%, piResultHandle%, iId%) :"_BS_ISteamInventory_AddPromoItem@12"
-BS_ISteamInventory_AddPromoItems%(pThis%, piResultHandle*, piIdsArray*, iArrayLength%):"_BS_ISteamInventory_AddPromoItems@16"
-BS_ISteamInventory_AddPromoItemsEx%(pThis%, piResultHandle%, piIdsArray%, iArrayLength%):"_BS_ISteamInventory_AddPromoItems@16"
-BS_ISteamInventory_ConsumeItem%(pThis%, piResultHandle*, iId%, iQuantity%) :"_BS_ISteamInventory_ConsumeItem@16"
-BS_ISteamInventory_ConsumeItemEx%(pThis%, piResultHandle%, iId%, iQuantity%) :"_BS_ISteamInventory_ConsumeItem@16"
-BS_ISteamInventory_ExchangeItems%(pThis%, piResultHandle*, piGenerateArray*, piGenerateQuantityArray*, iArrayGenerateLength%, piDestroyArray*, piDestroyQuantityArray*, iArrayDestroyLength%):"_BS_ISteamInventory_ExchangeItems@32"
-BS_ISteamInventory_ExchangeItemsEx%(pThis%, piResultHandle%, piGenerateArray%, piGenerateQuantityArray%, iArrayGenerateLength%, piDestroyArray%, piDestroyQuantityArray%, iArrayDestroyLength%):"_BS_ISteamInventory_ExchangeItems@32"
-BS_ISteamInventory_TransferItemQuantity%(pThis%, piResultHandle*, iSourceId%, iQuantity%, iDestId%):"_BS_ISteamInventory_TransferItemQuantity@20"
-BS_ISteamInventory_TransferItemQuantityEx%(pThis%, piResultHandle%, iSourceId%, iQuantity%, iDestId%):"_BS_ISteamInventory_TransferItemQuantity@20"
-BS_ISteamInventory_SendItemDropHeartbeat%(pThis%) :"_BS_ISteamInventory_SendItemDropHeartbeat@4"
-BS_ISteamInventory_TriggerItemDrop%(pThis%, piResultHandle*, iDropListId%) :"_BS_ISteamInventory_TriggerItemDrop@12"
-BS_ISteamInventory_TriggerItemDropEx%(pThis%, piResultHandle%, iDropListId%) :"_BS_ISteamInventory_TriggerItemDrop@12"
-BS_ISteamInventory_TradeItems%(pThis%, piResultHandle*, lSteamIdPartner%, piArrayGive*, piArrayGiveQuantity*, iArrayGiveLength%, piArrayGet*, piArrayGetQuantity*, iArrayGetLength%):"_BS_ISteamInventory_TradeItems@36"
-BS_ISteamInventory_TradeItemsEx%(pThis%, piResultHandle%, lSteamIdPartner%, piArrayGive%, piArrayGiveQuantity%, iArrayGiveLength%, piArrayGet%, piArrayGetQuantity%, iArrayGetLength%):"_BS_ISteamInventory_TradeItems@36"
-BS_ISteamInventory_LoadItemDefinitions%(pThis%) :"_BS_ISteamInventory_LoadItemDefinitions@4"
-BS_ISteamInventory_GetItemDefinitionIDs%(pThis%, piArrayId*, piArrayIdSize*) :"_BS_ISteamInventory_GetItemDefinitionIDs@12"
-BS_ISteamInventory_GetItemDefinitionIDsEx%(pThis%, piArrayId%, piArrayIdSize%) :"_BS_ISteamInventory_GetItemDefinitionIDs@12"
-BS_ISteamInventory_GetItemDefinitionProperty%(pThis%, iId%, cName$, pcValueBuffer*, piValueBufferSize*):"_BS_ISteamInventory_GetItemDefinitionProperty@20"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; Inventory -------------------------------------------------------------------
+BS_SteamInventory%() :"_BS_SteamInventory@0"
+BS_SteamGameServerInventory%() :"_BS_SteamGameServerInventory@0"
+BS_ISteamInventory_GetResultStatus%(pThis%, iResultHandle%) :"_BS_ISteamInventory_GetResultStatus@8"
+BS_ISteamInventory_GetResultItems%(pThis%, iResultHandle%, pItemsArray*, piItemsArraySize*):"_BS_ISteamInventory_GetResultItems@16"
+BS_ISteamInventory_GetResultItemsEx%(pThis%, iResultHandle%, pItemsArray%, piItemsArraySize%):"_BS_ISteamInventory_GetResultItems@16"
+BS_ISteamInventory_GetResultTimestamp%(pThis%, iResultHandle%) :"_BS_ISteamInventory_GetResultTimestamp@8"
+BS_ISteamInventory_CheckResultSteamID%(pThis%, iResultHandle%, lSteamIdExpected%):"_BS_ISteamInventory_GetResultTimestamp@12"
+BS_ISteamInventory_DestroyResult(pThis%, iResultHandle%) :"_BS_ISteamInventory_DestroyResult@8"
+BS_ISteamInventory_GetAllItems%(pThis%, piResultHandle*) :"_BS_ISteamInventory_GetAllItems@8"
+BS_ISteamInventory_GetAllItemsEx%(pThis%, piResultHandle%) :"_BS_ISteamInventory_GetAllItems@8"
+BS_ISteamInventory_GetItemsByID%(pThis%, piResultHandle*, plInstanceIds*, iInstanceIdCount%):"_BS_ISteamInventory_GetItemsByID@16"
+BS_ISteamInventory_GetItemsByIDEx%(pThis%, piResultHandle%, plInstanceIds%, iInstanceIdCount%):"_BS_ISteamInventory_GetItemsByID@16"
+BS_ISteamInventory_SerializeResult%(pThis%, iResultHandle%, pOutBuffer*, piOutBufferSize*):"_BS_ISteamInventory_SerializeResult@16"
+BS_ISteamInventory_SerializeResultEx%(pThis%, iResultHandle%, pOutBuffer%, piOutBufferSize%):"_BS_ISteamInventory_SerializeResult@16"
+BS_ISteamInventory_DeserializeResult%(pThis%, piResultHandle*, pBuffer*, iBufferSize%, bReservedMustBeFalse):"_BS_ISteamInventory_DeserializeResult@20"
+BS_ISteamInventory_DeserializeResultEx%(pThis%, piResultHandle%, pBuffer%, iBufferSize%, bReservedMustBeFalse):"_BS_ISteamInventory_DeserializeResult@20"
+BS_ISteamInventory_GenerateItems%(pThis%, piResultHandle*, piIdArray*, piQuantityArray*, iArrayLength%):"_BS_ISteamInventory_GenerateItems@20"
+BS_ISteamInventory_GenerateItemsEx%(pThis%, piResultHandle%, piIdArray%, piQuantityArray%, iArrayLength%):"_BS_ISteamInventory_GenerateItems@20"
+BS_ISteamInventory_GrantPromoItems%(pThis%, piResultHandle*) :"_BS_ISteamInventory_GrantPromoItems@8"
+BS_ISteamInventory_GrantPromoItemsEx%(pThis%, piResultHandle%) :"_BS_ISteamInventory_GrantPromoItems@8"
+BS_ISteamInventory_AddPromoItem%(pThis%, piResultHandle*, iId%) :"_BS_ISteamInventory_AddPromoItem@12"
+BS_ISteamInventory_AddPromoItemEx%(pThis%, piResultHandle%, iId%) :"_BS_ISteamInventory_AddPromoItem@12"
+BS_ISteamInventory_AddPromoItems%(pThis%, piResultHandle*, piIdsArray*, iArrayLength%):"_BS_ISteamInventory_AddPromoItems@16"
+BS_ISteamInventory_AddPromoItemsEx%(pThis%, piResultHandle%, piIdsArray%, iArrayLength%):"_BS_ISteamInventory_AddPromoItems@16"
+BS_ISteamInventory_ConsumeItem%(pThis%, piResultHandle*, iId%, iQuantity%) :"_BS_ISteamInventory_ConsumeItem@16"
+BS_ISteamInventory_ConsumeItemEx%(pThis%, piResultHandle%, iId%, iQuantity%) :"_BS_ISteamInventory_ConsumeItem@16"
+BS_ISteamInventory_ExchangeItems%(pThis%, piResultHandle*, piGenerateArray*, piGenerateQuantityArray*, iArrayGenerateLength%, piDestroyArray*, piDestroyQuantityArray*, iArrayDestroyLength%):"_BS_ISteamInventory_ExchangeItems@32"
+BS_ISteamInventory_ExchangeItemsEx%(pThis%, piResultHandle%, piGenerateArray%, piGenerateQuantityArray%, iArrayGenerateLength%, piDestroyArray%, piDestroyQuantityArray%, iArrayDestroyLength%):"_BS_ISteamInventory_ExchangeItems@32"
+BS_ISteamInventory_TransferItemQuantity%(pThis%, piResultHandle*, iSourceId%, iQuantity%, iDestId%):"_BS_ISteamInventory_TransferItemQuantity@20"
+BS_ISteamInventory_TransferItemQuantityEx%(pThis%, piResultHandle%, iSourceId%, iQuantity%, iDestId%):"_BS_ISteamInventory_TransferItemQuantity@20"
+BS_ISteamInventory_SendItemDropHeartbeat%(pThis%) :"_BS_ISteamInventory_SendItemDropHeartbeat@4"
+BS_ISteamInventory_TriggerItemDrop%(pThis%, piResultHandle*, iDropListId%) :"_BS_ISteamInventory_TriggerItemDrop@12"
+BS_ISteamInventory_TriggerItemDropEx%(pThis%, piResultHandle%, iDropListId%) :"_BS_ISteamInventory_TriggerItemDrop@12"
+BS_ISteamInventory_TradeItems%(pThis%, piResultHandle*, lSteamIdPartner%, piArrayGive*, piArrayGiveQuantity*, iArrayGiveLength%, piArrayGet*, piArrayGetQuantity*, iArrayGetLength%):"_BS_ISteamInventory_TradeItems@36"
+BS_ISteamInventory_TradeItemsEx%(pThis%, piResultHandle%, lSteamIdPartner%, piArrayGive%, piArrayGiveQuantity%, iArrayGiveLength%, piArrayGet%, piArrayGetQuantity%, iArrayGetLength%):"_BS_ISteamInventory_TradeItems@36"
+BS_ISteamInventory_LoadItemDefinitions%(pThis%) :"_BS_ISteamInventory_LoadItemDefinitions@4"
+BS_ISteamInventory_GetItemDefinitionIDs%(pThis%, piArrayId*, piArrayIdSize*) :"_BS_ISteamInventory_GetItemDefinitionIDs@12"
+BS_ISteamInventory_GetItemDefinitionIDsEx%(pThis%, piArrayId%, piArrayIdSize%) :"_BS_ISteamInventory_GetItemDefinitionIDs@12"
+BS_ISteamInventory_GetItemDefinitionProperty%(pThis%, iId%, cName$, pcValueBuffer*, piValueBufferSize*):"_BS_ISteamInventory_GetItemDefinitionProperty@20"
BS_ISteamInventory_GetItemDefinitionPropertyEx%(pThis%, iId%, cName$, pcValueBuffer%, piValueBufferSize%):"_BS_ISteamInventory_GetItemDefinitionProperty@20"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamMatchmaking.decls b/Resources/Decls/BlitzSteam_SteamMatchmaking.decls
index b4087a6..2923f02 100644
--- a/Resources/Decls/BlitzSteam_SteamMatchmaking.decls
+++ b/Resources/Decls/BlitzSteam_SteamMatchmaking.decls
@@ -1,21 +1,21 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; Matchmaking -----------------------------------------------------------------
-BS_SteamMatchmaking%() :"_BS_SteamMatchmaking@0"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; Matchmaking -----------------------------------------------------------------
+BS_SteamMatchmaking%() :"_BS_SteamMatchmaking@0"
; Todo
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamMatchmakingServers.decls b/Resources/Decls/BlitzSteam_SteamMatchmakingServers.decls
index cf3ea13..337e2f8 100644
--- a/Resources/Decls/BlitzSteam_SteamMatchmakingServers.decls
+++ b/Resources/Decls/BlitzSteam_SteamMatchmakingServers.decls
@@ -1,21 +1,42 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; MatchmakingServers ----------------------------------------------------------
-BS_SteamMatchmakingServers%() :"_BS_SteamMatchmakingServers@0"
-; Todo
\ No newline at end of file
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; MatchmakingServers ----------------------------------------------------------
+BS_SteamMatchmakingServers%() :"_BS_SteamMatchmakingServers@0"
+BS_ISteamMatchmakingServers_RequestInternetServerList%(pThis%, iApp%, ppchFilters*, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestInternetServerList@20"
+BS_ISteamMatchmakingServers_RequestInternetServerListEx%(pThis%, iApp%, ppchFilters%, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestInternetServerList@20"
+BS_ISteamMatchmakingServers_RequestLANServerList%(pThis%, iApp%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestLANServerList@12"
+BS_ISteamMatchmakingServers_RequestFriendsServerList%(pThis%, iApp%, ppchFilters*, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestFriendsServerList@20"
+BS_ISteamMatchmakingServers_RequestFriendsServerListEx%(pThis%, iApp%, ppchFilters%, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestFriendsServerList@20"
+BS_ISteamMatchmakingServers_RequestFavoritesServerList%(pThis%, iApp%, ppchFilters*, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestFavoritesServerList@20"
+BS_ISteamMatchmakingServers_RequestFavoritesServerListEx%(pThis%, iApp%, ppchFilters%, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestFavoritesServerList@20"
+BS_ISteamMatchmakingServers_RequestHistoryServerList%(pThis%, iApp%, ppchFilters*, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestHistoryServerList@20"
+BS_ISteamMatchmakingServers_RequestHistoryServerListEx%(pThis%, iApp%, ppchFilters%, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestHistoryServerList@20"
+BS_ISteamMatchmakingServers_RequestSpectatorServerList%(pThis%, iApp%, ppchFilters*, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestSpectatorServerList@20"
+BS_ISteamMatchmakingServers_RequestSpectatorServerListEx%(pThis%, iApp%, ppchFilters%, nFilters%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_RequestSpectatorServerList@20"
+BS_ISteamMatchmakingServers_ReleaseRequest%(pThis%, hServerListRequest%) :"_BS_ISteamMatchmakingServers_ReleaseRequest@8"
+BS_ISteamMatchmakingServers_GetServerDetails%(pThis%, hRequest%, iServer%) :"_BS_ISteamMatchmakingServers_GetServerDetails@12"
+BS_ISteamMatchmakingServers_CancelQuery%(pThis%, hRequest%) :"_BS_ISteamMatchmakingServers_CancelQuery@8"
+BS_ISteamMatchmakingServers_RefreshQuery%(pThis%, hRequest%) :"_BS_ISteamMatchmakingServers_RefreshQuery@8"
+BS_ISteamMatchmakingServers_IsRefreshing%(pThis%, hRequest%) :"_BS_ISteamMatchmakingServers_IsRefreshing@8"
+BS_ISteamMatchmakingServers_GetServerCount%(pThis%, hRequest%) :"_BS_ISteamMatchmakingServers_GetServerCount@8"
+BS_ISteamMatchmakingServers_RefreshServer%(pThis%, hRequest%) :"_BS_ISteamMatchmakingServers_RefreshServer@8"
+BS_ISteamMatchmakingServers_PingServer%(pThis%, unIP%, usPort%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_PingServer@16"
+BS_ISteamMatchmakingServers_PlayerDetails%(pThis%, unIP%, usPort%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_PlayerDetails@16"
+BS_ISteamMatchmakingServers_ServerRules%(pThis%, unIP%, usPort%, pRequestServersResponse%):"_BS_ISteamMatchmakingServers_ServerRules@16"
+BS_ISteamMatchmakingServers_CancelServerQuery%(pThis%, hServerQuery) :"_BS_ISteamMatchmakingServers_CancelServerQuery@8"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamMatchmakingTypes.decls b/Resources/Decls/BlitzSteam_SteamMatchmakingTypes.decls
new file mode 100644
index 0000000..47c09a7
--- /dev/null
+++ b/Resources/Decls/BlitzSteam_SteamMatchmakingTypes.decls
@@ -0,0 +1,78 @@
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; ISteamMatchmakingServerListResponse -----------------------------------------
+BS_ISteamMatchmakingServerListResponse_New%(Data%, pServerResponded%, pServerFailedToRespond%, pRefreshComplete%):"_BS_ISteamMatchmakingServerListResponse_New@16"
+BS_ISteamMatchmakingServerListResponse_Destroy%(pThis%):"_BS_ISteamMatchmakingServerListResponse_Destroy@4"
+;- Callback pServerResponded: Function(Data%, hRequest%, iServer%)
+;- Callback pServerFailedToRespond: Function(Data%, hRequest%, iServer%)
+;- Callback pRefreshComplete: Function(Data%)
+
+; ISteamMatchmakingPingResponse -----------------------------------------------
+BS_ISteamMatchmakingPingResponse_New%(Data%, pServerResponded%, pServerFailedToRespond%):"_BS_ISteamMatchmakingPingResponse_New@12"
+BS_ISteamMatchmakingPingResponse_Destroy%(pThis%):"_BS_ISteamMatchmakingPingResponse_Destroy@4"
+;- Callback pServerResponded: Function(Data%, TGameServerItem%)
+;- Callback pServerFailedToRespond: Function(Data%)
+
+; ISteamMatchmakingPlayersResponse --------------------------------------------
+BS_ISteamMatchmakingPlayersResponse_New%(Data%, pAddPlayerToList%, pPlayersFailedToRespond%, pPlayersRefreshComplete%):"_BS_ISteamMatchmakingPlayersResponse_New@16"
+BS_ISteamMatchmakingPlayersResponse_Destroy%(pThis%):"_BS_ISteamMatchmakingPlayersResponse_Destroy@4"
+;- Callback pAddPlayerToList: Function(Data%, pchName%, nScore%, flTimePlayer#)
+;- Callback pPlayersFailedToRespond: Function(Data%)
+;- Callback pPlayersRefreshComplete: Function(Data%)
+
+; ISteamMatchmakingRulesResponse ----------------------------------------------
+BS_ISteamMatchmakingRulesResponse_New%(Data%, pRulesResponded%, pRulesFailedToRespond%, pRulesRefreshComplete%):"_BS_ISteamMatchmakingRulesResponse_New@16"
+BS_ISteamMatchmakingRulesResponse_Destroy%(pThis%):"_BS_ISteamMatchmakingPlayersResponse_Destroy@4"
+;- Callback pRulesResponded: Function(Data%, pchRule%, pchValue%)
+;- Callback pRulesFailedToRespond: Function(Data%)
+;- Callback pRulesRefreshComplete: Function(Data%)
+
+; TGameServerItem -------------------------------------------------------------
+BS_TGameServerItem_GetName$(pThis%) :"_BS_TGameServerItem_GetName@4"
+BS_TGameServerItem_SetName(pThis%, cName$) :"_BS_TGameServerItem_SetName@8"
+BS_TGameServerItem_NetAdr%(pThis%) :"_BS_TGameServerItem_NetAdr@4"
+BS_TGameServerItem_Ping%(pThis%) :"_BS_TGameServerItem_Ping@4"
+BS_TGameServerItem_HadSuccessfulResponse%(pThis%) :"_BS_TGameServerItem_HadSuccessfulResponse@4"
+BS_TGameServerItem_DoNotRefresh%(pThis%) :"_BS_TGameServerItem_DoNotRefresh@4"
+BS_TGameServerItem_GameDir$(pThis%) :"_BS_TGameServerItem_GameDir@4"
+BS_TGameServerItem_Map$(pThis%) :"_BS_TGameServerItem_Map@4"
+BS_TGameServerItem_GameDescription$(pThis%) :"_BS_TGameServerItem_GameDescription@4"
+BS_TGameServerItem_AppId%(pThis%) :"_BS_TGameServerItem_AppId@4"
+BS_TGameServerItem_Players%(pThis%) :"_BS_TGameServerItem_Players@4"
+BS_TGameServerItem_MaxPlayers%(pThis%) :"_BS_TGameServerItem_MaxPlayers@4"
+BS_TGameServerItem_BotPlayers%(pThis%) :"_BS_TGameServerItem_BotPlayers@4"
+BS_TGameServerItem_Password%(pThis%) :"_BS_TGameServerItem_Password@4"
+BS_TGameServerItem_Secure%(pThis%) :"_BS_TGameServerItem_Secure@4"
+BS_TGameServerItem_TimeLastPlayed%(pThis%) :"_BS_TGameServerItem_TimeLastPlayed@4"
+BS_TGameServerItem_ServerVersion%(pThis%) :"_BS_TGameServerItem_ServerVersion@4"
+BS_TGameServerItem_GameTags$(pThis%) :"_BS_TGameServerItem_GameTags@4"
+BS_TGameServerItem_SteamID%(pThis%) :"_BS_TGameServerItem_SteamID@4"
+
+; TServerNetAdr ---------------------------------------------------------------
+BS_TServerNetAdr_Set(pThis%, pThat%) :"_BS_TServerNetAdr_Set@8"
+BS_TServerNetAdr_Init(pThis%, iIP%, iQueryPort%, iConnectionPort%) :"_BS_TServerNetAdr_Init@16"
+BS_TServerNetAdr_GetQueryPort%(pThis%) :"_BS_TServerNetAdr_GetQueryPort@4"
+BS_TServerNetAdr_SetQueryPort(pThis%, iPort%) :"_BS_TServerNetAdr_SetQueryPort@8"
+BS_TServerNetAdr_GetConnectionPort%(pThis%) :"_BS_TServerNetAdr_GetConnectionPort@4"
+BS_TServerNetAdr_SetConnectionPort(pThis%, iPort%) :"_BS_TServerNetAdr_SetConnectionPort@8"
+BS_TServerNetAdr_GetIP%(pThis%) :"_BS_TServerNetAdr_GetIP@4"
+BS_TServerNetAdr_SetIP(pThis%, iIP%) :"_BS_TServerNetAdr_SetIP@8"
+BS_TServerNetAdr_GetConnectionAddressString$(pThis%) :"_BS_TServerNetAdr_GetConnectionAddressString@4"
+BS_TServerNetAdr_GetQueryAddressString$(pThis%) :"_BS_TServerNetAdr_GetQueryAddressString@4"
+BS_TServerNetAdr_Compare%(pThis%, pThat%) :"_BS_TServerNetAdr_Compare@8"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamMusic.decls b/Resources/Decls/BlitzSteam_SteamMusic.decls
index 62e933d..2294d38 100644
--- a/Resources/Decls/BlitzSteam_SteamMusic.decls
+++ b/Resources/Decls/BlitzSteam_SteamMusic.decls
@@ -1,21 +1,21 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; Music -----------------------------------------------------------------------
-BS_SteamMusic%() :"_BS_SteamMusic@0"
-; Todo
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; Music -----------------------------------------------------------------------
+BS_SteamMusic%() :"_BS_SteamMusic@0"
+; Todo
diff --git a/Resources/Decls/BlitzSteam_SteamMusicRemote.decls b/Resources/Decls/BlitzSteam_SteamMusicRemote.decls
index 898d107..2093ce9 100644
--- a/Resources/Decls/BlitzSteam_SteamMusicRemote.decls
+++ b/Resources/Decls/BlitzSteam_SteamMusicRemote.decls
@@ -1,21 +1,21 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; MusicRemote -----------------------------------------------------------------
-BS_SteamMusicRemote%() :"_BS_SteamMusicRemote@0"
-; Todo
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; MusicRemote -----------------------------------------------------------------
+BS_SteamMusicRemote%() :"_BS_SteamMusicRemote@0"
+; Todo
diff --git a/Resources/Decls/BlitzSteam_SteamNetworking.decls b/Resources/Decls/BlitzSteam_SteamNetworking.decls
index 263951c..ecd6157 100644
--- a/Resources/Decls/BlitzSteam_SteamNetworking.decls
+++ b/Resources/Decls/BlitzSteam_SteamNetworking.decls
@@ -1,32 +1,32 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; Networking ------------------------------------------------------------------
-BS_SteamNetworking%() :"_BS_SteamNetworking@0"
-BS_SteamGameServerNetworking%() :"_BS_SteamGameServerNetworking@0"
-BS_ISteamNetworking_SendP2PPacket%(pThis%, lRemoteSteamId%, pData*, iDataSize%, EP2PSendType%, iChannel%):"_BS_ISteamNetworking_SendP2PPacket@24"
-BS_ISteamNetworking_SendP2PPacketEx%(pThis%, lRemoteSteamId%, pData%, iDataSize%, EP2PSendType%, iChannel%):"_BS_ISteamNetworking_SendP2PPacket@24"
-BS_ISteamNetworking_IsP2PPacketAvailable%(pThis%, piSize*, iChannel%) :"_BS_ISteamNetworking_IsP2PPacketAvailable@12"
-BS_ISteamNetworking_IsP2PPacketAvailableEx%(pThis%, piSize%, iChannel%) :"_BS_ISteamNetworking_IsP2PPacketAvailableEx@12"
-BS_ISteamNetworking_ReadP2PPacket%(pThis%, pBuffer*, iBufferSize%, piMessageSize*, lRemoteSteamId%, iChannel%):"_BS_ISteamNetworking_ReadP2PPacket@24"
-BS_ISteamNetworking_ReadP2PPacketEx%(pThis%, pBuffer%, iBufferSize%, piMessageSize%, lRemoteSteamId%, iChannel%):"_BS_ISteamNetworking_ReadP2PPacket@24"
-BS_ISteamNetworking_AcceptP2PSessionWithUser%(pThis%, lRemoteSteamId%) :"_BS_ISteamNetworking_AcceptP2PSessionWithUser@8"
-BS_ISteamNetworking_CloseP2PSessionWithUser%(pThis%, lRemoteSteamId%) :"_BS_ISteamNetworking_CloseP2PSessionWithUser@8"
-BS_ISteamNetworking_CloseP2PChannelWithUser%(pThis%, lRemoteSteamId%, iChannel%):"_BS_ISteamNetworking_CloseP2PChannelWithUser@12"
-BS_ISteamNetworking_GetP2PSessionState%(pThis%, lRemoteSteamId%, pConnectionState*):"_BS_ISteamNetworking_GetP2PSessionState@12"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; Networking ------------------------------------------------------------------
+BS_SteamNetworking%() :"_BS_SteamNetworking@0"
+BS_SteamGameServerNetworking%() :"_BS_SteamGameServerNetworking@0"
+BS_ISteamNetworking_SendP2PPacket%(pThis%, lRemoteSteamId%, pData*, iDataSize%, EP2PSendType%, iChannel%):"_BS_ISteamNetworking_SendP2PPacket@24"
+BS_ISteamNetworking_SendP2PPacketEx%(pThis%, lRemoteSteamId%, pData%, iDataSize%, EP2PSendType%, iChannel%):"_BS_ISteamNetworking_SendP2PPacket@24"
+BS_ISteamNetworking_IsP2PPacketAvailable%(pThis%, piSize*, iChannel%) :"_BS_ISteamNetworking_IsP2PPacketAvailable@12"
+BS_ISteamNetworking_IsP2PPacketAvailableEx%(pThis%, piSize%, iChannel%) :"_BS_ISteamNetworking_IsP2PPacketAvailable@12"
+BS_ISteamNetworking_ReadP2PPacket%(pThis%, pBuffer*, iBufferSize%, piMessageSize*, plRemoteSteamId*, iChannel%):"_BS_ISteamNetworking_ReadP2PPacket@24"
+BS_ISteamNetworking_ReadP2PPacketEx%(pThis%, pBuffer%, iBufferSize%, piMessageSize%, plRemoteSteamId%, iChannel%):"_BS_ISteamNetworking_ReadP2PPacket@24"
+BS_ISteamNetworking_AcceptP2PSessionWithUser%(pThis%, lRemoteSteamId%) :"_BS_ISteamNetworking_AcceptP2PSessionWithUser@8"
+BS_ISteamNetworking_CloseP2PSessionWithUser%(pThis%, lRemoteSteamId%) :"_BS_ISteamNetworking_CloseP2PSessionWithUser@8"
+BS_ISteamNetworking_CloseP2PChannelWithUser%(pThis%, lRemoteSteamId%, iChannel%):"_BS_ISteamNetworking_CloseP2PChannelWithUser@12"
+BS_ISteamNetworking_GetP2PSessionState%(pThis%, lRemoteSteamId%, pConnectionState*):"_BS_ISteamNetworking_GetP2PSessionState@12"
BS_ISteamNetworking_AllowP2PPacketRelay%(pThis%, bAllow%) :"_BS_ISteamNetworking_AllowP2PPacketRelay@8"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamRemoteStorage.decls b/Resources/Decls/BlitzSteam_SteamRemoteStorage.decls
index d06a0ec..ea3f10b 100644
--- a/Resources/Decls/BlitzSteam_SteamRemoteStorage.decls
+++ b/Resources/Decls/BlitzSteam_SteamRemoteStorage.decls
@@ -1,21 +1,21 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; RemoteStorage ---------------------------------------------------------------
-BS_SteamRemoteStorage%() :"_BS_SteamRemoteStorage@0"
-; Todo
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; RemoteStorage ---------------------------------------------------------------
+BS_SteamRemoteStorage%() :"_BS_SteamRemoteStorage@0"
+; Todo
diff --git a/Resources/Decls/BlitzSteam_SteamScreenshots.decls b/Resources/Decls/BlitzSteam_SteamScreenshots.decls
index 7e37a02..671fa4b 100644
--- a/Resources/Decls/BlitzSteam_SteamScreenshots.decls
+++ b/Resources/Decls/BlitzSteam_SteamScreenshots.decls
@@ -1,21 +1,21 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; Screenshots -----------------------------------------------------------------
-BS_SteamScreenshots%() :"_BS_SteamScreenshots@0"
-; Todo
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; Screenshots -----------------------------------------------------------------
+BS_SteamScreenshots%() :"_BS_SteamScreenshots@0"
+; Todo
diff --git a/Resources/Decls/BlitzSteam_SteamUGC.decls b/Resources/Decls/BlitzSteam_SteamUGC.decls
index a91fe13..ce0a3e6 100644
--- a/Resources/Decls/BlitzSteam_SteamUGC.decls
+++ b/Resources/Decls/BlitzSteam_SteamUGC.decls
@@ -1,22 +1,22 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; UGC -------------------------------------------------------------------------
-BS_SteamUGC%() :"_BS_SteamUGC@0"
-BS_SteamGameServerUGC%() :"_BS_SteamGameServerUGC@0"
-; Todo
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; UGC -------------------------------------------------------------------------
+BS_SteamUGC%() :"_BS_SteamUGC@0"
+BS_SteamGameServerUGC%() :"_BS_SteamGameServerUGC@0"
+; Todo
diff --git a/Resources/Decls/BlitzSteam_SteamUnifiedMessages.decls b/Resources/Decls/BlitzSteam_SteamUnifiedMessages.decls
index 4d29356..84e4d38 100644
--- a/Resources/Decls/BlitzSteam_SteamUnifiedMessages.decls
+++ b/Resources/Decls/BlitzSteam_SteamUnifiedMessages.decls
@@ -1,20 +1,20 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; UnifiedMessages -------------------------------------------------------------
-BS_SteamUnifiedMessages%() :"_BS_SteamUnifiedMessages@0"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; UnifiedMessages -------------------------------------------------------------
+BS_SteamUnifiedMessages%() :"_BS_SteamUnifiedMessages@0"
diff --git a/Resources/Decls/BlitzSteam_SteamUser.decls b/Resources/Decls/BlitzSteam_SteamUser.decls
index d51d81e..54037e4 100644
--- a/Resources/Decls/BlitzSteam_SteamUser.decls
+++ b/Resources/Decls/BlitzSteam_SteamUser.decls
@@ -1,49 +1,49 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; User ------------------------------------------------------------------------
-BS_SteamUser%() :"_BS_SteamUser@0"
-BS_ISteamUser_GetHSteamUser%(pThis%) :"_BS_ISteamUser_GetHSteamUser@4"
-BS_ISteamUser_IsLoggedOn%(pThis%) :"_BS_ISteamUser_IsLoggedOn@4"
-BS_ISteamUser_GetSteamID%(pThis%) :"_BS_ISteamUser_GetSteamID@4"
-BS_ISteamUser_InitiateGameConnection%(pThis%, pAuthBlob*, iAuthBlobSize%, lSteamId%, iIp%, sPort%, bSecure%):"_BS_ISteamUser_InitiateGameConnection@28"
-BS_ISteamUser_InitiateGameConnectionEx%(pThis%, pAuthBlob%, iAuthBlobSize%, lSteamId%, iIp%, sPort%, bSecure%):"_BS_ISteamUser_InitiateGameConnection@28"
-BS_ISteamUser_TerminateGameConnection(pThis%, iIp%, sPort%) :"_BS_ISteamUser_TerminateGameConnection@12"
-BS_ISteamUser_TrackAppUsageEvent(pThis%, iAppId%, EAppUsageEvent%, cExtraInfo$) :"_BS_ISteamUser_TrackAppUsageEvent@16"
-BS_ISteamUser_GetUserDataFolder%(pThis%, pBuffer*, iBufferSize%) :"_BS_ISteamUser_GetUserDataFolder@12"
-BS_ISteamUser_StartVoiceRecording(pThis%) :"_BS_ISteamUser_StartVoiceRecording@4"
-BS_ISteamUser_StopVoiceRecording(pThis%) :"_BS_ISteamUser_StopVoiceRecording@4"
-BS_ISteamUser_GetAvailableVoice%(pThis%, pCompressed*, pUncompressed*, nDesiredSampleRate%):"_BS_ISteamUser_GetAvailableVoice@16"
-BS_ISteamUser_GetAvailableVoiceEx%(pThis%, pCompressed%, pUncompressed%, nDesiredSampleRate%):"_BS_ISteamUser_GetAvailableVoice@16"
-BS_ISteamUser_GetVoice%(pThis%, bCompressed%, pCompressed*, iCompressedSize%, piCompressedBytesWritten*, bUncompressed%, pUncompressed*, iUncompressedSize%, piUncompressedBytesWritten*, iSampleRate%):"_BS_ISteamUser_GetVoice@36"
-BS_ISteamUser_GetVoiceEx%(pThisEx%, bCompressed%, pCompressed%, iCompressedSize%, piCompressedBytesWritten%, bUncompressed%, pUncompressed%, iUncompressedSize%, piUncompressedBytesWritten%, iSampleRate%):"_BS_ISteamUser_GetVoice@36"
-BS_ISteamUser_DecompressVoice(pThis%, pCompressed*, iCompressedSize%, pUncompressed*, iUncompressedSize%, iUncompressedBytesWritten*, iSampleRate%):"_BS_ISteamUser_DecompressVoice@28"
-BS_ISteamUser_DecompressVoiceEx(pThis%, pCompressed*, iCompressedSize%, pUncompressed%, iUncompressedSize%, iUncompressedBytesWritten%, iSampleRate%):"_BS_ISteamUser_DecompressVoice@28"
-BS_ISteamUser_GetVoiceOptimalSampleRate%(pThis%) :"_BS_ISteamUser_GetVoiceOptimalSampleRate@4"
-BS_ISteamUser_GetAuthSessionTicket%(pThis%, pTicket*, iTicketSize%, piTicketSize*):"_BS_ISteamUser_GetAuthSessionTicket@12"
-BS_ISteamUser_BeginAuthSession%(pThis%, pAuthTicket*, iAuthTicketSize%, lSteamId%):"_BS_ISteamUser_BeginAuthSession@16"
-BS_ISteamUser_EndAuthSession(pThis%, lSteamId%) :"_BS_ISteamUser_EndAuthSession@8"
-BS_ISteamUser_CancelAuthTicket(pThis%, hAuthTicket%) :"_BS_ISteamUser_CancelAuthTicket@8"
-BS_ISteamUser_UserHasLicenseForApp%(pThis%, lSteamId%, iAppId%) :"_BS_ISteamUser_UserHasLicenseForApp@12"
-BS_ISteamUser_IsBehindNAT%(pThis%) :"_BS_ISteamUser_IsBehindNAT@4"
-BS_ISteamUser_AdvertiseGame%(pThis%, lSteamId%, iIp%, sPort%) :"_BS_ISteamUser_AdvertiseGame@16"
-BS_ISteamUser_RequestEncryptedAppTicket%(pThis%, pData*, iDataSize%) :"_BS_ISteamUser_RequestEncryptedAppTicket@12"
-BS_ISteamUser_GetEncryptedAppTicket%(pThis%, pTicket*, iTicketSize%, piTicketSize*):"_BS_ISteamUser_GetEncryptedAppTicket@16"
-BS_ISteamUser_GetGameBadgeLevel%(pThis%, iSeries%, bFoil%) :"_BS_ISteamUser_GetGameBadgeLevel@12"
-BS_ISteamUser_GetPlayerSteamLevel%(pThis%) :"_BS_ISteamUser_GetPlayerSteamLevel@4"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; User ------------------------------------------------------------------------
+BS_SteamUser%() :"_BS_SteamUser@0"
+BS_ISteamUser_GetHSteamUser%(pThis%) :"_BS_ISteamUser_GetHSteamUser@4"
+BS_ISteamUser_IsLoggedOn%(pThis%) :"_BS_ISteamUser_IsLoggedOn@4"
+BS_ISteamUser_GetSteamID%(pThis%) :"_BS_ISteamUser_GetSteamID@4"
+BS_ISteamUser_InitiateGameConnection%(pThis%, pAuthBlob*, iAuthBlobSize%, lSteamId%, iIp%, sPort%, bSecure%):"_BS_ISteamUser_InitiateGameConnection@28"
+BS_ISteamUser_InitiateGameConnectionEx%(pThis%, pAuthBlob%, iAuthBlobSize%, lSteamId%, iIp%, sPort%, bSecure%):"_BS_ISteamUser_InitiateGameConnection@28"
+BS_ISteamUser_TerminateGameConnection(pThis%, iIp%, sPort%) :"_BS_ISteamUser_TerminateGameConnection@12"
+BS_ISteamUser_TrackAppUsageEvent(pThis%, iAppId%, EAppUsageEvent%, cExtraInfo$) :"_BS_ISteamUser_TrackAppUsageEvent@16"
+BS_ISteamUser_GetUserDataFolder%(pThis%, pBuffer*, iBufferSize%) :"_BS_ISteamUser_GetUserDataFolder@12"
+BS_ISteamUser_StartVoiceRecording(pThis%) :"_BS_ISteamUser_StartVoiceRecording@4"
+BS_ISteamUser_StopVoiceRecording(pThis%) :"_BS_ISteamUser_StopVoiceRecording@4"
+BS_ISteamUser_GetAvailableVoice%(pThis%, pCompressed*, pUncompressed*, nDesiredSampleRate%):"_BS_ISteamUser_GetAvailableVoice@16"
+BS_ISteamUser_GetAvailableVoiceEx%(pThis%, pCompressed%, pUncompressed%, nDesiredSampleRate%):"_BS_ISteamUser_GetAvailableVoice@16"
+BS_ISteamUser_GetVoice%(pThis%, bCompressed%, pCompressed*, iCompressedSize%, piCompressedBytesWritten*, bUncompressed%, pUncompressed*, iUncompressedSize%, piUncompressedBytesWritten*, iSampleRate%):"_BS_ISteamUser_GetVoice@36"
+BS_ISteamUser_GetVoiceEx%(pThisEx%, bCompressed%, pCompressed%, iCompressedSize%, piCompressedBytesWritten%, bUncompressed%, pUncompressed%, iUncompressedSize%, piUncompressedBytesWritten%, iSampleRate%):"_BS_ISteamUser_GetVoice@36"
+BS_ISteamUser_DecompressVoice(pThis%, pCompressed*, iCompressedSize%, pUncompressed*, iUncompressedSize%, iUncompressedBytesWritten*, iSampleRate%):"_BS_ISteamUser_DecompressVoice@28"
+BS_ISteamUser_DecompressVoiceEx(pThis%, pCompressed*, iCompressedSize%, pUncompressed%, iUncompressedSize%, iUncompressedBytesWritten%, iSampleRate%):"_BS_ISteamUser_DecompressVoice@28"
+BS_ISteamUser_GetVoiceOptimalSampleRate%(pThis%) :"_BS_ISteamUser_GetVoiceOptimalSampleRate@4"
+BS_ISteamUser_GetAuthSessionTicket%(pThis%, pTicket*, iTicketSize%, piTicketSize*):"_BS_ISteamUser_GetAuthSessionTicket@16"
+BS_ISteamUser_BeginAuthSession%(pThis%, pAuthTicket*, iAuthTicketSize%, lSteamId%):"_BS_ISteamUser_BeginAuthSession@16"
+BS_ISteamUser_EndAuthSession(pThis%, lSteamId%) :"_BS_ISteamUser_EndAuthSession@8"
+BS_ISteamUser_CancelAuthTicket(pThis%, hAuthTicket%) :"_BS_ISteamUser_CancelAuthTicket@8"
+BS_ISteamUser_UserHasLicenseForApp%(pThis%, lSteamId%, iAppId%) :"_BS_ISteamUser_UserHasLicenseForApp@12"
+BS_ISteamUser_IsBehindNAT%(pThis%) :"_BS_ISteamUser_IsBehindNAT@4"
+BS_ISteamUser_AdvertiseGame%(pThis%, lSteamId%, iIp%, sPort%) :"_BS_ISteamUser_AdvertiseGame@16"
+BS_ISteamUser_RequestEncryptedAppTicket%(pThis%, pData*, iDataSize%) :"_BS_ISteamUser_RequestEncryptedAppTicket@12"
+BS_ISteamUser_GetEncryptedAppTicket%(pThis%, pTicket*, iTicketSize%, piTicketSize*):"_BS_ISteamUser_GetEncryptedAppTicket@16"
+BS_ISteamUser_GetGameBadgeLevel%(pThis%, iSeries%, bFoil%) :"_BS_ISteamUser_GetGameBadgeLevel@12"
+BS_ISteamUser_GetPlayerSteamLevel%(pThis%) :"_BS_ISteamUser_GetPlayerSteamLevel@4"
BS_ISteamUser_RequestStoreAuthURL%(pThis%, cRedirectUrl$) :"_BS_ISteamUser_RequestStoreAuthURL@8"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamUserStats.decls b/Resources/Decls/BlitzSteam_SteamUserStats.decls
index 140c251..8f04e41 100644
--- a/Resources/Decls/BlitzSteam_SteamUserStats.decls
+++ b/Resources/Decls/BlitzSteam_SteamUserStats.decls
@@ -1,77 +1,77 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; UserStats -------------------------------------------------------------------
-BS_UserStats%() :"_BS_UserStats@0"
-BS_UserStats_RequestCurrentStats%(pThis%) :"_BS_UserStats_RequestCurrentStats@4"
-BS_UserStats_GetStat%(pThis%, cName$, pData*) :"_BS_UserStats_GetStat@12"
-BS_UserStats_GetStatEx%(pThis%, cName$, pData%) :"_BS_UserStats_GetStat@12"
-BS_UserStats_GetStatF%(pThis%, cName$, pData*) :"_BS_UserStats_GetStatF@12"
-BS_UserStats_GetStatFEx%(pThis%, cName$, pData%) :"_BS_UserStats_GetStatF@12"
-BS_UserStats_SetStat%(pThis%, cName$, pData%) :"_BS_UserStats_SetStat@12"
-BS_UserStats_SetStatF%(pThis%, cName$, pData#) :"_BS_UserStats_SetStatF@12"
-BS_UserStats_UpdateAvgRateStat%(pThis%, cName$, fCountThisSession#, dSessionLength%):"_BS_UserStats_UpdateAvgRateStat@16"
-BS_UserStats_GetAchievement%(pThis%, cName$, pbAchieved*) :"_BS_UserStats_GetAchievement@12"
-BS_UserStats_GetAchievementEx%(pThis%, cName$, pbAchieved%) :"_BS_UserStats_GetAchievement@12"
-BS_UserStats_SetAchievement%(pThis%, cName$) :"_BS_UserStats_SetAchievement@8"
-BS_UserStats_ClearAchievement%(pThis%, cName$) :"_BS_UserStats_ClearAchievement@8"
-BS_UserStats_GetAchievementAndUnlockTime%(pThis%, cName$, pbAchieved*, piUnlockTime*):"_BS_UserStats_GetAchievementAndUnlockTime@16"
-BS_UserStats_GetAchievementAndUnlockTimeEx%(pThis%, cName$, pbAchieved%, piUnlockTime%):"_BS_UserStats_GetAchievementAndUnlockTime@16"
-BS_UserStats_StoreStats%(pThis%) :"_BS_UserStats_StoreStats@4"
-BS_UserStats_GetAchievementIcon%(pThis%, cName$) :"_BS_UserStats_GetAchievementIcon@8"
-BS_UserStats_GetAchievementDisplayAttribute$(pThis%, cName$, cKey$) :"_BS_UserStats_GetAchievementDisplayAttribute@12"
-BS_UserStats_IndicateAchievementProgress%(pThis%, cName$, iProgress%, iMaxProgress%):"_BS_UserStats_IndicateAchievementProgress@16"
-BS_UserStats_GetNumAchievements%(pThis%) :"_BS_UserStats_GetNumAchievements@4"
-BS_UserStats_GetAchievementName$(pThis%, iAchievement%) :"_BS_UserStats_GetAchievementName@8"
-BS_UserStats_RequestUserStats%(pThis%, lSteamId%) :"_BS_UserStats_RequestUserStats@8"
-BS_UserStats_GetUserStat%(pThis%, lSteamId%, cName$, pData*) :"_BS_UserStats_GetUserStat@16"
-BS_UserStats_GetUserStatEx%(pThis%, lSteamId%, cName$, pData%) :"_BS_UserStats_GetUserStat@16"
-BS_UserStats_GetUserStatF%(pThis%, lSteamId%, cName$, pData*) :"_BS_UserStats_GetUserStatF@16"
-BS_UserStats_GetUserStatFEx%(pThis%, lSteamId%, cName$, pData%) :"_BS_UserStats_GetUserStatF@16"
-BS_UserStats_GetUserAchievement%(pThis%, lSteamId%, cName$, pbAchieved*) :"_BS_UserStats_GetUserAchievement@16"
-BS_UserStats_GetUserAchievementEx%(pThis%, lSteamId%, cName$, pbAchieved%) :"_BS_UserStats_GetUserAchievement@16"
-BS_UserStats_GetUserAchievementAndUnlockTime%(pThis%, lSteamId%, cName$, pbAchieved*, piUnlockTime*):"_BS_UserStats_GetUserAchievementAndUnlockTime@20"
-BS_UserStats_GetUserAchievementAndUnlockTimeEx%(pThis%, lSteamId%, cName$, pbAchieved%, piUnlockTime%):"_BS_UserStats_GetUserAchievementAndUnlockTime@20"
-BS_UserStats_ResetAllStats%(pThis%, bAchievementsToo%) :"_BS_UserStats_ResetAllStats@8"
-BS_UserStats_FindOrCreateLeaderboard%(pThis%, cLeaderboardName$, eLeaderboardSortMethod%, eLeaderboardDisplayType%):"_BS_UserStats_FindOrCreateLeaderboard@16"
-BS_UserStats_FindLeaderboard%(pThis%, cLeaderboardName$) :"_BS_UserStats_FindLeaderboard@8"
-BS_UserStats_GetLeaderboardName$(pThis%, hSteamLeaderboard%) :"_BS_UserStats_GetLeaderboardName@8"
-BS_UserStats_GetLeaderboardEntryCount%(pThis%, hSteamLeaderboard%) :"_BS_UserStats_GetLeaderboardEntryCount@8"
-BS_UserStats_GetLeaderboardSortMethod%(pThis%, hSteamLeaderboard%) :"_BS_UserStats_GetLeaderboardSortMethod@8"
-BS_UserStats_GetLeaderboardDisplayType%(pThis%, hSteamLeaderboard%) :"_BS_UserStats_GetLeaderboardDisplayType@8"
-BS_UserStats_DownloadLeaderboardEntries%(pThis%, hSteamLeaderboard%, eLeaderboardDataRequest%, iRangeStart%, iRangeEnd%):"_BS_UserStats_DownloadLeaderboardEntries@20"
-BS_UserStats_DownloadLeaderboardEntriesForUsers%(pThis%, hSteamLeaderboard%, plUsers*, iUserCount%):"_BS_UserStats_DownloadLeaderboardEntriesForUsers@16"
-BS_UserStats_DownloadLeaderboardEntriesForUsersEx%(pThis%, hSteamLeaderboard%, plUsers%, iUserCount%):"_BS_UserStats_DownloadLeaderboardEntriesForUsers@16"
-BS_UserStats_GetDownloadedLeaderboardEntry%(lpSteamUsers%, hSteamLeaderboardEntries%, iIndex%, pLeaderboardEntry*, pDetails*, iDetailsMax%):"_BS_UserStats_GetDownloadedLeaderboardEntry@24"
-BS_UserStats_GetDownloadedLeaderboardEntryEx%(lpSteamUsers%, hSteamLeaderboardEntries%, iIndex%, pLeaderboardEntry%, pDetails%, iDetailsMax%):"_BS_UserStats_GetDownloadedLeaderboardEntry@24"
-BS_UserStats_UploadLeaderboardScore%(pThis%, hSteamLeaderboard%, eLeaderboardUploadScoreMethod%, iScore%, pScoreDetails*, iScoreDetailsCount%):"_BS_UserStats_UploadLeaderboardScore@24"
-BS_UserStats_UploadLeaderboardScoreEx%(pThis%, hSteamLeaderboard%, eLeaderboardUploadScoreMethod%, iScore%, pScoreDetails%, iScoreDetailsCount%):"_BS_UserStats_UploadLeaderboardScore@24"
-BS_UserStats_AttachLeaderboardUGC%(pThis%, hSteamLeaderboard%, hUGC%) :"_BS_UserStats_AttachLeaderboardUGC@12"
-BS_UserStats_GetNumberOfCurrentPlayers%(pThis%) :"_BS_UserStats_GetNumberOfCurrentPlayers@4"
-BS_UserStats_RequestGlobalAchievementPercentages%(pThis%) :"_BS_UserStats_RequestGlobalAchievementPercentages@4"
-BS_UserStats_GetMostAchievedAchievementInfo%(pThis%, cName$, iNameLength%, pfPercent*, pbAchieved*):"_BS_UserStats_GetMostAchievedAchievementInfo@20"
-BS_UserStats_GetMostAchievedAchievementInfoEx%(pThis%, cName$, iNameLength%, pfPercent%, pbAchieved%):"_BS_UserStats_GetMostAchievedAchievementInfo@20"
-BS_UserStats_GetNextMostAchievedAchievementInfo%(pThis%, iIteratorPrevious%, cName$, iNameLength%, pfPercent*, pbAchieved*):"_BS_UserStats_GetNextMostAchievedAchievementInfo@24"
-BS_UserStats_GetNextMostAchievedAchievementInfoEx%(pThis%, iIteratorPrevious%, cName$, iNameLength%, pfPercent%, pbAchieved%):"_BS_UserStats_GetNextMostAchievedAchievementInfo@24"
-BS_UserStats_GetAchievementAchievedPercent%(pThis%, cName$, pfPercent*) :"_BS_UserStats_GetAchievementAchievedPercent@12"
-BS_UserStats_GetAchievementAchievedPercentEx%(pThis%, cName$, pfPercent%) :"_BS_UserStats_GetAchievementAchievedPercent@12"
-BS_UserStats_RequestGlobalStats%(pThis%, iHistoryDays%) :"_BS_UserStats_RequestGlobalStats@8"
-BS_UserStats_GetGlobalStatL%(pThis, cStatName$, plData%) :"_BS_UserStats_GetGlobalStatL@12"
-BS_UserStats_GetGlobalStatD%(pThis, cStatName$, pdData%) :"_BS_UserStats_GetGlobalStatD@12"
-BS_UserStats_GetGlobalStatHistoryL%(pThis, cStatName$, plDataArray%, iDataSize%):"BS_UserStats_GetGlobalStatHistoryL@16"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; UserStats -------------------------------------------------------------------
+BS_UserStats%() :"_BS_UserStats@0"
+BS_UserStats_RequestCurrentStats%(pThis%) :"_BS_UserStats_RequestCurrentStats@4"
+BS_UserStats_GetStat%(pThis%, cName$, pData*) :"_BS_UserStats_GetStat@12"
+BS_UserStats_GetStatEx%(pThis%, cName$, pData%) :"_BS_UserStats_GetStat@12"
+BS_UserStats_GetStatF%(pThis%, cName$, pData*) :"_BS_UserStats_GetStatF@12"
+BS_UserStats_GetStatFEx%(pThis%, cName$, pData%) :"_BS_UserStats_GetStatF@12"
+BS_UserStats_SetStat%(pThis%, cName$, pData%) :"_BS_UserStats_SetStat@12"
+BS_UserStats_SetStatF%(pThis%, cName$, pData#) :"_BS_UserStats_SetStatF@12"
+BS_UserStats_UpdateAvgRateStat%(pThis%, cName$, fCountThisSession#, dSessionLength%):"_BS_UserStats_UpdateAvgRateStat@16"
+BS_UserStats_GetAchievement%(pThis%, cName$, pbAchieved*) :"_BS_UserStats_GetAchievement@12"
+BS_UserStats_GetAchievementEx%(pThis%, cName$, pbAchieved%) :"_BS_UserStats_GetAchievement@12"
+BS_UserStats_SetAchievement%(pThis%, cName$) :"_BS_UserStats_SetAchievement@8"
+BS_UserStats_ClearAchievement%(pThis%, cName$) :"_BS_UserStats_ClearAchievement@8"
+BS_UserStats_GetAchievementAndUnlockTime%(pThis%, cName$, pbAchieved*, piUnlockTime*):"_BS_UserStats_GetAchievementAndUnlockTime@16"
+BS_UserStats_GetAchievementAndUnlockTimeEx%(pThis%, cName$, pbAchieved%, piUnlockTime%):"_BS_UserStats_GetAchievementAndUnlockTime@16"
+BS_UserStats_StoreStats%(pThis%) :"_BS_UserStats_StoreStats@4"
+BS_UserStats_GetAchievementIcon%(pThis%, cName$) :"_BS_UserStats_GetAchievementIcon@8"
+BS_UserStats_GetAchievementDisplayAttribute$(pThis%, cName$, cKey$) :"_BS_UserStats_GetAchievementDisplayAttribute@12"
+BS_UserStats_IndicateAchievementProgress%(pThis%, cName$, iProgress%, iMaxProgress%):"_BS_UserStats_IndicateAchievementProgress@16"
+BS_UserStats_GetNumAchievements%(pThis%) :"_BS_UserStats_GetNumAchievements@4"
+BS_UserStats_GetAchievementName$(pThis%, iAchievement%) :"_BS_UserStats_GetAchievementName@8"
+BS_UserStats_RequestUserStats%(pThis%, lSteamId%) :"_BS_UserStats_RequestUserStats@8"
+BS_UserStats_GetUserStat%(pThis%, lSteamId%, cName$, pData*) :"_BS_UserStats_GetUserStat@16"
+BS_UserStats_GetUserStatEx%(pThis%, lSteamId%, cName$, pData%) :"_BS_UserStats_GetUserStat@16"
+BS_UserStats_GetUserStatF%(pThis%, lSteamId%, cName$, pData*) :"_BS_UserStats_GetUserStatF@16"
+BS_UserStats_GetUserStatFEx%(pThis%, lSteamId%, cName$, pData%) :"_BS_UserStats_GetUserStatF@16"
+BS_UserStats_GetUserAchievement%(pThis%, lSteamId%, cName$, pbAchieved*) :"_BS_UserStats_GetUserAchievement@16"
+BS_UserStats_GetUserAchievementEx%(pThis%, lSteamId%, cName$, pbAchieved%) :"_BS_UserStats_GetUserAchievement@16"
+BS_UserStats_GetUserAchievementAndUnlockTime%(pThis%, lSteamId%, cName$, pbAchieved*, piUnlockTime*):"_BS_UserStats_GetUserAchievementAndUnlockTime@20"
+BS_UserStats_GetUserAchievementAndUnlockTimeEx%(pThis%, lSteamId%, cName$, pbAchieved%, piUnlockTime%):"_BS_UserStats_GetUserAchievementAndUnlockTime@20"
+BS_UserStats_ResetAllStats%(pThis%, bAchievementsToo%) :"_BS_UserStats_ResetAllStats@8"
+BS_UserStats_FindOrCreateLeaderboard%(pThis%, cLeaderboardName$, eLeaderboardSortMethod%, eLeaderboardDisplayType%):"_BS_UserStats_FindOrCreateLeaderboard@16"
+BS_UserStats_FindLeaderboard%(pThis%, cLeaderboardName$) :"_BS_UserStats_FindLeaderboard@8"
+BS_UserStats_GetLeaderboardName$(pThis%, hSteamLeaderboard%) :"_BS_UserStats_GetLeaderboardName@8"
+BS_UserStats_GetLeaderboardEntryCount%(pThis%, hSteamLeaderboard%) :"_BS_UserStats_GetLeaderboardEntryCount@8"
+BS_UserStats_GetLeaderboardSortMethod%(pThis%, hSteamLeaderboard%) :"_BS_UserStats_GetLeaderboardSortMethod@8"
+BS_UserStats_GetLeaderboardDisplayType%(pThis%, hSteamLeaderboard%) :"_BS_UserStats_GetLeaderboardDisplayType@8"
+BS_UserStats_DownloadLeaderboardEntries%(pThis%, hSteamLeaderboard%, eLeaderboardDataRequest%, iRangeStart%, iRangeEnd%):"_BS_UserStats_DownloadLeaderboardEntries@20"
+BS_UserStats_DownloadLeaderboardEntriesForUsers%(pThis%, hSteamLeaderboard%, plUsers*, iUserCount%):"_BS_UserStats_DownloadLeaderboardEntriesForUsers@16"
+BS_UserStats_DownloadLeaderboardEntriesForUsersEx%(pThis%, hSteamLeaderboard%, plUsers%, iUserCount%):"_BS_UserStats_DownloadLeaderboardEntriesForUsers@16"
+BS_UserStats_GetDownloadedLeaderboardEntry%(lpSteamUsers%, hSteamLeaderboardEntries%, iIndex%, pLeaderboardEntry*, pDetails*, iDetailsMax%):"_BS_UserStats_GetDownloadedLeaderboardEntry@24"
+BS_UserStats_GetDownloadedLeaderboardEntryEx%(lpSteamUsers%, hSteamLeaderboardEntries%, iIndex%, pLeaderboardEntry%, pDetails%, iDetailsMax%):"_BS_UserStats_GetDownloadedLeaderboardEntry@24"
+BS_UserStats_UploadLeaderboardScore%(pThis%, hSteamLeaderboard%, eLeaderboardUploadScoreMethod%, iScore%, pScoreDetails*, iScoreDetailsCount%):"_BS_UserStats_UploadLeaderboardScore@24"
+BS_UserStats_UploadLeaderboardScoreEx%(pThis%, hSteamLeaderboard%, eLeaderboardUploadScoreMethod%, iScore%, pScoreDetails%, iScoreDetailsCount%):"_BS_UserStats_UploadLeaderboardScore@24"
+BS_UserStats_AttachLeaderboardUGC%(pThis%, hSteamLeaderboard%, hUGC%) :"_BS_UserStats_AttachLeaderboardUGC@12"
+BS_UserStats_GetNumberOfCurrentPlayers%(pThis%) :"_BS_UserStats_GetNumberOfCurrentPlayers@4"
+BS_UserStats_RequestGlobalAchievementPercentages%(pThis%) :"_BS_UserStats_RequestGlobalAchievementPercentages@4"
+BS_UserStats_GetMostAchievedAchievementInfo%(pThis%, cName$, iNameLength%, pfPercent*, pbAchieved*):"_BS_UserStats_GetMostAchievedAchievementInfo@20"
+BS_UserStats_GetMostAchievedAchievementInfoEx%(pThis%, cName$, iNameLength%, pfPercent%, pbAchieved%):"_BS_UserStats_GetMostAchievedAchievementInfo@20"
+BS_UserStats_GetNextMostAchievedAchievementInfo%(pThis%, iIteratorPrevious%, cName$, iNameLength%, pfPercent*, pbAchieved*):"_BS_UserStats_GetNextMostAchievedAchievementInfo@24"
+BS_UserStats_GetNextMostAchievedAchievementInfoEx%(pThis%, iIteratorPrevious%, cName$, iNameLength%, pfPercent%, pbAchieved%):"_BS_UserStats_GetNextMostAchievedAchievementInfo@24"
+BS_UserStats_GetAchievementAchievedPercent%(pThis%, cName$, pfPercent*) :"_BS_UserStats_GetAchievementAchievedPercent@12"
+BS_UserStats_GetAchievementAchievedPercentEx%(pThis%, cName$, pfPercent%) :"_BS_UserStats_GetAchievementAchievedPercent@12"
+BS_UserStats_RequestGlobalStats%(pThis%, iHistoryDays%) :"_BS_UserStats_RequestGlobalStats@8"
+BS_UserStats_GetGlobalStatL%(pThis, cStatName$, plData%) :"_BS_UserStats_GetGlobalStatL@12"
+BS_UserStats_GetGlobalStatD%(pThis, cStatName$, pdData%) :"_BS_UserStats_GetGlobalStatD@12"
+BS_UserStats_GetGlobalStatHistoryL%(pThis, cStatName$, plDataArray%, iDataSize%):"BS_UserStats_GetGlobalStatHistoryL@16"
BS_UserStats_GetGlobalStatHistoryD%(pThis, cStatName$, pdDataArray%, iDataSize%):"BS_UserStats_GetGlobalStatHistoryD@16"
\ No newline at end of file
diff --git a/Resources/Decls/BlitzSteam_SteamUtils.decls b/Resources/Decls/BlitzSteam_SteamUtils.decls
index 400869f..25c78ab 100644
--- a/Resources/Decls/BlitzSteam_SteamUtils.decls
+++ b/Resources/Decls/BlitzSteam_SteamUtils.decls
@@ -1,21 +1,21 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; Utils -----------------------------------------------------------------------
-BS_SteamUtils%() :"_BS_SteamUtils@0"
-BS_SteamGameServerUtils%() :"_BS_SteamGameServerUtils@0"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; Utils -----------------------------------------------------------------------
+BS_SteamUtils%() :"_BS_SteamUtils@0"
+BS_SteamGameServerUtils%() :"_BS_SteamGameServerUtils@0"
diff --git a/Resources/Decls/BlitzSteam_SteamVideo.decls b/Resources/Decls/BlitzSteam_SteamVideo.decls
index ff9c34d..f86493c 100644
--- a/Resources/Decls/BlitzSteam_SteamVideo.decls
+++ b/Resources/Decls/BlitzSteam_SteamVideo.decls
@@ -1,20 +1,20 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-.lib "BlitzSteam.dll"
-
-; Utils -----------------------------------------------------------------------
-BS_SteamVideo%() :"_BS_SteamVideo@0"
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+.lib "BlitzSteam.dll"
+
+; Utils -----------------------------------------------------------------------
+BS_SteamVideo%() :"_BS_SteamVideo@0"
diff --git a/Resources/Examples/SteamAPI_Example.bb b/Resources/Examples/SteamAPI_Example.bb
index a4fb7bc..42cf291 100644
--- a/Resources/Examples/SteamAPI_Example.bb
+++ b/Resources/Examples/SteamAPI_Example.bb
@@ -1,66 +1,66 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-Include "../BlitzSteam.bb"
-
-; Initialize Steam before your next call to Graphics.
-If BS_SteamAPI_Init() = False Then
- RuntimeError "Steam: Failed to initialize!"
-EndIf
-
-Const FPS = 30
-Const FPS_MULT# = 1.0 / FPS
-
-; Demo Scene
-Graphics3D 1024, 768, 32, 2
-SetBuffer BackBuffer()
-
-Local demoTimer = CreateTimer(FPS)
-
-Local demoRoot = CreatePivot()
-
-Local demoCameraRoot = CreatePivot(demoRoot)
-Local demoCamera = CreateCamera(demoCameraRoot)
-MoveEntity demoCamera, 0, 0, -10
-
-Local demoCube = CreateCube(demoRoot)
-
-Local EndGame = False
-Repeat
- Cls
-
- ;! Update
- ; End on Escape
- EndGame = KeyHit(1)
-
- TurnEntity demoCube, 1 * FPS_MULT, 3 * FPS_MULT, 2.332 * FPS_MULT
-
- ;! Render 3D
- RenderWorld
-
- ;! Render 2D
- Text 0, 0, "Escape to Quit"
-
- ;! Update Window
- Flip 0
- WaitTimer(demoTimer)
-Until EndGame = True
-
-; Shut down Steam as the last action of your program.
-BS_SteamAPI_Shutdown()
-End
-;~IDEal Editor Parameters:
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+Include "../BlitzSteam.bb"
+
+; Initialize Steam before your next call to Graphics.
+If BS_SteamAPI_Init() = False Then
+ RuntimeError "Steam: Failed to initialize!"
+EndIf
+
+Const FPS = 30
+Const FPS_MULT# = 1.0 / FPS
+
+; Demo Scene
+Graphics3D 1024, 768, 32, 2
+SetBuffer BackBuffer()
+
+Local demoTimer = CreateTimer(FPS)
+
+Local demoRoot = CreatePivot()
+
+Local demoCameraRoot = CreatePivot(demoRoot)
+Local demoCamera = CreateCamera(demoCameraRoot)
+MoveEntity demoCamera, 0, 0, -10
+
+Local demoCube = CreateCube(demoRoot)
+
+Local EndGame = False
+Repeat
+ Cls
+
+ ;! Update
+ ; End on Escape
+ EndGame = KeyHit(1)
+
+ TurnEntity demoCube, 1 * FPS_MULT, 3 * FPS_MULT, 2.332 * FPS_MULT
+
+ ;! Render 3D
+ RenderWorld
+
+ ;! Render 2D
+ Text 0, 0, "Escape to Quit"
+
+ ;! Update Window
+ Flip 0
+ WaitTimer(demoTimer)
+Until EndGame = True
+
+; Shut down Steam as the last action of your program.
+BS_SteamAPI_Shutdown()
+End
+;~IDEal Editor Parameters:
;~C#Blitz3D
\ No newline at end of file
diff --git a/Resources/Examples/SteamAppList_Example.bb b/Resources/Examples/SteamAppList_Example.bb
index 3f4b8b4..121d855 100644
--- a/Resources/Examples/SteamAppList_Example.bb
+++ b/Resources/Examples/SteamAppList_Example.bb
@@ -1,128 +1,128 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-Include "../BlitzSteam.bb"
-
-; Initialize Steam before your next call to Graphics.
-If BS_SteamAPI_Init() = False Then
- RuntimeError "Steam: Failed to initialize!"
-EndIf
-
-Const FPS = 30
-Const FPS_MULT# = 1.0 / FPS
-
-; Demo Scene
-Graphics3D 1024, 768, 32, 2
-SetBuffer BackBuffer()
-
-Local demoTimer = CreateTimer(FPS)
-
-Local demoRoot = CreatePivot()
-
-Local demoCameraRoot = CreatePivot(demoRoot)
-Local demoCamera = CreateCamera(demoCameraRoot)
-MoveEntity demoCamera, 0, 0, -10
-
-Local demoCube = CreateCube(demoRoot)
-
-; SteamAppList stuff
-Type SteamAppList
- Field AppId%
- Field Name$
- Field InstallDir$
- Field BuildId%
-End Type
-Global SteamAppList_Count%
-
-Function SteamAppList_Fill()
- SteamAppList_Count = BS_ISteamAppList_GetNumInstalledApps(BS_SteamAppList())
-
- Local Buffer = CreateBank(4 * SteamAppList_Count)
- Local AppNameBuffer = CreateBank(1024)
- Local PathBuffer = CreateBank(260)
-
- Local AppIdCount = BS_ISteamAppList_GetInstalledApps(BS_SteamAppList(), Buffer, SteamAppList_Count)
- Delete Each SteamAppList
- For Index = 0 To AppIdCount - 1
- Local AppId = PeekInt(Buffer, Index*4)
-
- Local SAL.SteamAppList = New SteamAppList
- SAL\AppId = AppId
- Local AppNameLen = BS_ISteamAppList_GetAppName(BS_SteamAppList(), AppId, AppNameBuffer, 1024)
- SAL\Name = PeekCString(AppNameBuffer, 0, AppNameLen)
- Local PathLen = BS_ISteamAppList_GetAppInstallDir(BS_SteamAppList(), AppId, PathBuffer, 260)
- SAL\InstallDir = PeekCString(PathBuffer, 0, PathLen)
- SAL\BuildId = BS_ISteamAppList_GetAppBuildId(BS_SteamAppList(), AppId)
- Next
-
- FreeBank AppNameBuffer
- FreeBank PathBuffer
- FreeBank Buffer
-End Function
-
-Function PeekCString$(Bank, Offset=0, Length=-1)
- Local Out$ = "", Pos = Offset
- While Abs(Length) > 0
- Length = Length - 1
-
- Local by = PeekByte(Bank, Pos)
- If by = 0 Then
- Length = 0
- Else
- Out = Out + Chr(by)
- EndIf
-
- Pos = Pos + 1
- Wend
- Return Out
-End Function
-
-SteamAppList_Fill()
-
-; Main Loop
-Local EndGame = False
-Repeat
- Cls
-
- ;! Update
- ; End on Escape
- EndGame = KeyHit(1)
-
- TurnEntity demoCube, 1 * FPS_MULT, 3 * FPS_MULT, 2.332 * FPS_MULT
-
- ;! Render 3D
- RenderWorld
-
- ;! Render 2D
- Text 0, 0, "Escape to Quit"
-
- Text 0,15, "Installed Apps: " + SteamAppList_Count
- Local SAL.SteamAppList, Index = 0
- For SAL.SteamAppList = Each SteamAppList
- Index = Index + 1
- Text 0, 30 + Index* 15, RSet(SAL\AppId, 6) + "/" + RSet(SAL\BuildId, 8) + ": " + SAL\Name + " (Installed: '" + SAL\InstallDir + "')"
- Next
-
- ;! Update Window
- Flip 0
- WaitTimer(demoTimer)
-Until EndGame = True
-
-; Shut down Steam as the last action of your program.
-BS_SteamAPI_Shutdown()
-End
-;~IDEal Editor Parameters:
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+Include "../BlitzSteam.bb"
+
+; Initialize Steam before your next call to Graphics.
+If BS_SteamAPI_Init() = False Then
+ RuntimeError "Steam: Failed to initialize!"
+EndIf
+
+Const FPS = 30
+Const FPS_MULT# = 1.0 / FPS
+
+; Demo Scene
+Graphics3D 1024, 768, 32, 2
+SetBuffer BackBuffer()
+
+Local demoTimer = CreateTimer(FPS)
+
+Local demoRoot = CreatePivot()
+
+Local demoCameraRoot = CreatePivot(demoRoot)
+Local demoCamera = CreateCamera(demoCameraRoot)
+MoveEntity demoCamera, 0, 0, -10
+
+Local demoCube = CreateCube(demoRoot)
+
+; SteamAppList stuff
+Type SteamAppList
+ Field AppId%
+ Field Name$
+ Field InstallDir$
+ Field BuildId%
+End Type
+Global SteamAppList_Count%
+
+Function SteamAppList_Fill()
+ SteamAppList_Count = BS_ISteamAppList_GetNumInstalledApps(BS_SteamAppList())
+
+ Local Buffer = CreateBank(4 * SteamAppList_Count)
+ Local AppNameBuffer = CreateBank(1024)
+ Local PathBuffer = CreateBank(260)
+
+ Local AppIdCount = BS_ISteamAppList_GetInstalledApps(BS_SteamAppList(), Buffer, SteamAppList_Count)
+ Delete Each SteamAppList
+ For Index = 0 To AppIdCount - 1
+ Local AppId = PeekInt(Buffer, Index*4)
+
+ Local SAL.SteamAppList = New SteamAppList
+ SAL\AppId = AppId
+ Local AppNameLen = BS_ISteamAppList_GetAppName(BS_SteamAppList(), AppId, AppNameBuffer, 1024)
+ SAL\Name = PeekCString(AppNameBuffer, 0, AppNameLen)
+ Local PathLen = BS_ISteamAppList_GetAppInstallDir(BS_SteamAppList(), AppId, PathBuffer, 260)
+ SAL\InstallDir = PeekCString(PathBuffer, 0, PathLen)
+ SAL\BuildId = BS_ISteamAppList_GetAppBuildId(BS_SteamAppList(), AppId)
+ Next
+
+ FreeBank AppNameBuffer
+ FreeBank PathBuffer
+ FreeBank Buffer
+End Function
+
+Function PeekCString$(Bank, Offset=0, Length=-1)
+ Local Out$ = "", Pos = Offset
+ While Abs(Length) > 0
+ Length = Length - 1
+
+ Local by = PeekByte(Bank, Pos)
+ If by = 0 Then
+ Length = 0
+ Else
+ Out = Out + Chr(by)
+ EndIf
+
+ Pos = Pos + 1
+ Wend
+ Return Out
+End Function
+
+SteamAppList_Fill()
+
+; Main Loop
+Local EndGame = False
+Repeat
+ Cls
+
+ ;! Update
+ ; End on Escape
+ EndGame = KeyHit(1)
+
+ TurnEntity demoCube, 1 * FPS_MULT, 3 * FPS_MULT, 2.332 * FPS_MULT
+
+ ;! Render 3D
+ RenderWorld
+
+ ;! Render 2D
+ Text 0, 0, "Escape to Quit"
+
+ Text 0,15, "Installed Apps: " + SteamAppList_Count
+ Local SAL.SteamAppList, Index = 0
+ For SAL.SteamAppList = Each SteamAppList
+ Index = Index + 1
+ Text 0, 30 + Index* 15, RSet(SAL\AppId, 6) + "/" + RSet(SAL\BuildId, 8) + ": " + SAL\Name + " (Installed: '" + SAL\InstallDir + "')"
+ Next
+
+ ;! Update Window
+ Flip 0
+ WaitTimer(demoTimer)
+Until EndGame = True
+
+; Shut down Steam as the last action of your program.
+BS_SteamAPI_Shutdown()
+End
+;~IDEal Editor Parameters:
;~C#Blitz3D
\ No newline at end of file
diff --git a/Resources/Examples/SteamApps_Example.bb b/Resources/Examples/SteamApps_Example.bb
index cefcbb1..445f882 100644
--- a/Resources/Examples/SteamApps_Example.bb
+++ b/Resources/Examples/SteamApps_Example.bb
@@ -1,179 +1,179 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-Include "../BlitzSteam.bb"
-
-; Initialize Steam before your next call to Graphics.
-If BS_SteamAPI_Init() = False Then
- RuntimeError "Steam: Failed to initialize!"
-EndIf
-
-Const FPS = 30
-Const FPS_MULT# = 1.0 / FPS
-
-; Demo Scene
-Graphics3D 1024, 768, 32, 2
-SetBuffer BackBuffer()
-
-Local demoTimer = CreateTimer(FPS)
-Local demoRoot = CreatePivot()
-Local demoCameraRoot = CreatePivot(demoRoot)
-Local demoCamera = CreateCamera(demoCameraRoot)
-MoveEntity demoCamera, 0, 0, -10
-Local demoCube = CreateCube(demoRoot)
-
-; SteamApps Stuff
-Type SteamAppsDLC
- Field Id%
- Field Available%
- Field Name$
-End Type
-Global SteamAppsDLC_Count
-
-Function SteamAppsDLC_Fill()
- Local IdBuffer = CreateBank(4)
- Local AvailableBuffer = CreateBank(4)
- Local NameBuffer = CreateBank(1024)
-
- SteamAppsDLC_Count = BS_ISteamApps_GetDLCCount(BS_SteamApps())
- Delete Each SteamAppsDLC
- For Index = 0 To SteamAppsDLC_Count - 1
- If BS_ISteamApps_GetDLCDataByIndex(BS_SteamApps(), Index, IdBuffer, AvailableBuffer, NameBuffer, 1024)
- Local SAD.SteamAppsDLC = New SteamAppsDLC
- SAD\Id = PeekInt(IdBuffer, 0)
- SAD\Available = PeekInt(AvailableBuffer, 0)
- SAD\Name = PeekCString(NameBuffer, 0, 1024)
- Else
- SteamAppsDLC_Count = SteamAppsDLC_Count - 1
- EndIf
- Next
-
- FreeBank NameBuffer
- FreeBank AvailableBuffer
- FreeBank IdBuffer
-End Function
-
-Type SteamAppsDepots
- Field DepotId
-End Type
-Global SteamAppsDepots_Count
-
-Function SteamAppsDepots_Fill()
- Local DepotsBuffer
- ; Exercise: Do this one yourself with the above Type. It's not that hard.
-End Function
-
-Function PeekCString$(Bank, Offset=0, Length=-1)
- Local Out$ = "", Pos = Offset
- While Abs(Length) > 0
- Length = Length - 1
-
- Local by = PeekByte(Bank, Pos)
- If by = 0 Then
- Length = 0
- Else
- Out = Out + Chr(by)
- EndIf
-
- Pos = Pos + 1
- Wend
- Return Out
-End Function
-
-Local BetaBuffer = CreateBank(1024)
-BS_ISteamApps_GetCurrentBetaName(BS_SteamApps(), BetaBuffer, 1024)
-Local Beta$ = PeekCString(BetaBuffer, 0, 1024)
-FreeBank BetaBuffer
-
-Local AppInstallDir$, AppInstallDirBuffer = CreateBank(260)
-BS_ISteamApps_GetAppInstallDir(BS_SteamApps(), 480, AppInstallDirBuffer, 260)
-AppInstallDir = PeekCString(AppInstallDirBuffer, 0, 260)
-FreeBank AppInstallDirBuffer
-
-Local llOwner = BS_ISteamApps_GetAppOwner(BS_SteamApps())
-Local OwnerId$ = "[U:" + BS_CSteamID_GetAccountInstance(llOwner) + ":" + BS_CSteamID_GetAccountID(llOwner) + "] STEAM_" + (BS_CSteamID_GetEAccountType(llOwner) - 1) + ":" + (BS_CSteamID_GetEUniverse(llOwner) - 1) + ":" + (BS_CSteamID_GetAccountID(llOwner) / 2)
-BS_CSteamID_Destroy llOwner
-
-; Main Loop
-Local EndGame = False
-Repeat
- Cls
-
- ;! Update
- ; End on Escape
- EndGame = KeyHit(1)
-
- TurnEntity demoCube, 1 * FPS_MULT, 3 * FPS_MULT, 2.332 * FPS_MULT
-
- ;! Render 3D
- RenderWorld
-
- ;! Render 2D
- Text 0, 0, "Escape to Quit"
-
- Text 0, 30, "Is Subscribed? " + BS_ISteamApps_IsSubscribed(BS_SteamApps())
- Text 0, 45, "Is Low Violence? " + BS_ISteamApps_IsLowViolence(BS_SteamApps())
- Text 0, 60, "Is Cybercafe? " + BS_ISteamApps_IsCybercafe(BS_SteamApps())
- Text 0, 75, "Is VAC Banned? " + BS_ISteamApps_IsVACBanned(BS_SteamApps())
- Text 0, 90, "Current Game Language: " + BS_ISteamApps_GetCurrentGameLanguage(BS_SteamApps())
- Text 0,105, "Available Game Languages: " + BS_ISteamApps_GetAvailableGameLanguages(BS_SteamApps())
- Text 0,120, "Is Subscribed App (480)? " + BS_ISteamApps_IsSubscribedApp(BS_SteamApps(), 480)
- Text 0,135, "Is DLC (323180) Installed? " + BS_ISteamApps_IsDlcInstalled(BS_SteamApps(), 323180) ; Portal 2 Soundtrack DLC
- Text 0,150, "Earliest Purchase Unix Time (480): " + BS_ISteamApps_GetEarliestPurchaseUnixTime(BS_SteamApps(), 480)
- Text 0,165, "Is Subscribed from Free Weekend? " + BS_ISteamApps_IsSubscribedFromFreeWeekend(BS_SteamApps())
- Text 0,180, "DLC Count: " + BS_ISteamApps_GetDLCCount(BS_SteamApps())
- Text 0,195, "Current Beta Name: " + Beta
- Text 0,210, "App Install Dir: " + AppInstallDir$
- Text 0,225, "Is App Installed (480): " + BS_ISteamApps_IsAppInstalled(BS_SteamApps(), 480)
- Text 0,240, "App Owner Id: " + OwnerId
- Text 0,255, "App Built Id: " + BS_ISteamApps_GetAppBuildId(BS_SteamApps())
-
- ; BS_ISteamApps_GetLanchQueryParam$(BS_SteamApps(), pchKey$)
- ; // Returns the associated launch param if the game is run via steam://run///?param1=value1;param2=value2;param3=value3 etc.
- ; // Parameter names starting with the character '@' are reserved for internal use and will always return and empty string.
- ; // Parameter names starting with an underscore '_' are reserved for steam features -- they can be queried by the game,
- ; // but it is advised that you not param names beginning with an underscore for your own features.
-
- ; BS_ISteamApps_MarkContentCorrupt signals steam that game files are corrupt or missing. Forces a validation after quit and before next start.
-
- ; How To Use: BS_ISteamApps_RequestProofOfPurchaseKey(BS_SteamApps(), nAppId)
- ; // Request cd-key for yourself or owned DLC. If you are interested in this
- ; // data then make sure you provide us with a list of valid keys to be distributed
- ; // to users when they purchase the game, before the game ships.
- ; // You'll receive an AppProofOfPurchaseKeyResponse_t callback when
- ; // the key is available (which may be immediately).
- ; Example (Spacewar) does not have CD-Keys.
-
- Text 512, 0, "DLCs: " + SteamAppsDLC_Count
- Local Index = 0, SAD.SteamAppsDLC
- For SAD = Each SteamAppsDLC
- Text 512, 15 + Index * 15, SAD\Id + "(" + SAD\Available + "): " + SAD\Name
- ; You could install DLCs from the app itself, BS_ISteamApps_InstallDLC, BS_ISteamApps_UninstallDLC
- ; BS_ISteamApps_GetDlcDownloadProgress allows you to check the progress, BlitzUtility's LongLong stuff is useful here.
-
- Index = Index + 1
- Next
-
- ;! Update Window
- Flip 0
- WaitTimer(demoTimer)
-Until EndGame = True
-
-; Shut down Steam as the last action of your program.
-BS_SteamAPI_Shutdown()
-End
-;~IDEal Editor Parameters:
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+Include "../BlitzSteam.bb"
+
+; Initialize Steam before your next call to Graphics.
+If BS_SteamAPI_Init() = False Then
+ RuntimeError "Steam: Failed to initialize!"
+EndIf
+
+Const FPS = 30
+Const FPS_MULT# = 1.0 / FPS
+
+; Demo Scene
+Graphics3D 1024, 768, 32, 2
+SetBuffer BackBuffer()
+
+Local demoTimer = CreateTimer(FPS)
+Local demoRoot = CreatePivot()
+Local demoCameraRoot = CreatePivot(demoRoot)
+Local demoCamera = CreateCamera(demoCameraRoot)
+MoveEntity demoCamera, 0, 0, -10
+Local demoCube = CreateCube(demoRoot)
+
+; SteamApps Stuff
+Type SteamAppsDLC
+ Field Id%
+ Field Available%
+ Field Name$
+End Type
+Global SteamAppsDLC_Count
+
+Function SteamAppsDLC_Fill()
+ Local IdBuffer = CreateBank(4)
+ Local AvailableBuffer = CreateBank(4)
+ Local NameBuffer = CreateBank(1024)
+
+ SteamAppsDLC_Count = BS_ISteamApps_GetDLCCount(BS_SteamApps())
+ Delete Each SteamAppsDLC
+ For Index = 0 To SteamAppsDLC_Count - 1
+ If BS_ISteamApps_GetDLCDataByIndex(BS_SteamApps(), Index, IdBuffer, AvailableBuffer, NameBuffer, 1024)
+ Local SAD.SteamAppsDLC = New SteamAppsDLC
+ SAD\Id = PeekInt(IdBuffer, 0)
+ SAD\Available = PeekInt(AvailableBuffer, 0)
+ SAD\Name = PeekCString(NameBuffer, 0, 1024)
+ Else
+ SteamAppsDLC_Count = SteamAppsDLC_Count - 1
+ EndIf
+ Next
+
+ FreeBank NameBuffer
+ FreeBank AvailableBuffer
+ FreeBank IdBuffer
+End Function
+
+Type SteamAppsDepots
+ Field DepotId
+End Type
+Global SteamAppsDepots_Count
+
+Function SteamAppsDepots_Fill()
+ Local DepotsBuffer
+ ; Exercise: Do this one yourself with the above Type. It's not that hard.
+End Function
+
+Function PeekCString$(Bank, Offset=0, Length=-1)
+ Local Out$ = "", Pos = Offset
+ While Abs(Length) > 0
+ Length = Length - 1
+
+ Local by = PeekByte(Bank, Pos)
+ If by = 0 Then
+ Length = 0
+ Else
+ Out = Out + Chr(by)
+ EndIf
+
+ Pos = Pos + 1
+ Wend
+ Return Out
+End Function
+
+Local BetaBuffer = CreateBank(1024)
+BS_ISteamApps_GetCurrentBetaName(BS_SteamApps(), BetaBuffer, 1024)
+Local Beta$ = PeekCString(BetaBuffer, 0, 1024)
+FreeBank BetaBuffer
+
+Local AppInstallDir$, AppInstallDirBuffer = CreateBank(260)
+BS_ISteamApps_GetAppInstallDir(BS_SteamApps(), 480, AppInstallDirBuffer, 260)
+AppInstallDir = PeekCString(AppInstallDirBuffer, 0, 260)
+FreeBank AppInstallDirBuffer
+
+Local llOwner = BS_ISteamApps_GetAppOwner(BS_SteamApps())
+Local OwnerId$ = "[U:" + BS_CSteamID_GetAccountInstance(llOwner) + ":" + BS_CSteamID_GetAccountID(llOwner) + "] STEAM_" + (BS_CSteamID_GetEAccountType(llOwner) - 1) + ":" + (BS_CSteamID_GetEUniverse(llOwner) - 1) + ":" + (BS_CSteamID_GetAccountID(llOwner) / 2)
+BS_CSteamID_Destroy llOwner
+
+; Main Loop
+Local EndGame = False
+Repeat
+ Cls
+
+ ;! Update
+ ; End on Escape
+ EndGame = KeyHit(1)
+
+ TurnEntity demoCube, 1 * FPS_MULT, 3 * FPS_MULT, 2.332 * FPS_MULT
+
+ ;! Render 3D
+ RenderWorld
+
+ ;! Render 2D
+ Text 0, 0, "Escape to Quit"
+
+ Text 0, 30, "Is Subscribed? " + BS_ISteamApps_IsSubscribed(BS_SteamApps())
+ Text 0, 45, "Is Low Violence? " + BS_ISteamApps_IsLowViolence(BS_SteamApps())
+ Text 0, 60, "Is Cybercafe? " + BS_ISteamApps_IsCybercafe(BS_SteamApps())
+ Text 0, 75, "Is VAC Banned? " + BS_ISteamApps_IsVACBanned(BS_SteamApps())
+ Text 0, 90, "Current Game Language: " + BS_ISteamApps_GetCurrentGameLanguage(BS_SteamApps())
+ Text 0,105, "Available Game Languages: " + BS_ISteamApps_GetAvailableGameLanguages(BS_SteamApps())
+ Text 0,120, "Is Subscribed App (480)? " + BS_ISteamApps_IsSubscribedApp(BS_SteamApps(), 480)
+ Text 0,135, "Is DLC (323180) Installed? " + BS_ISteamApps_IsDlcInstalled(BS_SteamApps(), 323180) ; Portal 2 Soundtrack DLC
+ Text 0,150, "Earliest Purchase Unix Time (480): " + BS_ISteamApps_GetEarliestPurchaseUnixTime(BS_SteamApps(), 480)
+ Text 0,165, "Is Subscribed from Free Weekend? " + BS_ISteamApps_IsSubscribedFromFreeWeekend(BS_SteamApps())
+ Text 0,180, "DLC Count: " + BS_ISteamApps_GetDLCCount(BS_SteamApps())
+ Text 0,195, "Current Beta Name: " + Beta
+ Text 0,210, "App Install Dir: " + AppInstallDir$
+ Text 0,225, "Is App Installed (480): " + BS_ISteamApps_IsAppInstalled(BS_SteamApps(), 480)
+ Text 0,240, "App Owner Id: " + OwnerId
+ Text 0,255, "App Built Id: " + BS_ISteamApps_GetAppBuildId(BS_SteamApps())
+
+ ; BS_ISteamApps_GetLanchQueryParam$(BS_SteamApps(), pchKey$)
+ ; // Returns the associated launch param if the game is run via steam://run///?param1=value1;param2=value2;param3=value3 etc.
+ ; // Parameter names starting with the character '@' are reserved for internal use and will always return and empty string.
+ ; // Parameter names starting with an underscore '_' are reserved for steam features -- they can be queried by the game,
+ ; // but it is advised that you not param names beginning with an underscore for your own features.
+
+ ; BS_ISteamApps_MarkContentCorrupt signals steam that game files are corrupt or missing. Forces a validation after quit and before next start.
+
+ ; How To Use: BS_ISteamApps_RequestProofOfPurchaseKey(BS_SteamApps(), nAppId)
+ ; // Request cd-key for yourself or owned DLC. If you are interested in this
+ ; // data then make sure you provide us with a list of valid keys to be distributed
+ ; // to users when they purchase the game, before the game ships.
+ ; // You'll receive an AppProofOfPurchaseKeyResponse_t callback when
+ ; // the key is available (which may be immediately).
+ ; Example (Spacewar) does not have CD-Keys.
+
+ Text 512, 0, "DLCs: " + SteamAppsDLC_Count
+ Local Index = 0, SAD.SteamAppsDLC
+ For SAD = Each SteamAppsDLC
+ Text 512, 15 + Index * 15, SAD\Id + "(" + SAD\Available + "): " + SAD\Name
+ ; You could install DLCs from the app itself, BS_ISteamApps_InstallDLC, BS_ISteamApps_UninstallDLC
+ ; BS_ISteamApps_GetDlcDownloadProgress allows you to check the progress, BlitzUtility's LongLong stuff is useful here.
+
+ Index = Index + 1
+ Next
+
+ ;! Update Window
+ Flip 0
+ WaitTimer(demoTimer)
+Until EndGame = True
+
+; Shut down Steam as the last action of your program.
+BS_SteamAPI_Shutdown()
+End
+;~IDEal Editor Parameters:
;~C#Blitz3D
\ No newline at end of file
diff --git a/Resources/Examples/SteamController_Example.bb b/Resources/Examples/SteamController_Example.bb
index 1aa4377..695ffce 100644
--- a/Resources/Examples/SteamController_Example.bb
+++ b/Resources/Examples/SteamController_Example.bb
@@ -1,68 +1,68 @@
-; BlitzSteam - Steam wrapper for Blitz
-; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-;
-; This program is free software: you can redistribute it and/or modify
-; it under the terms of the GNU Lesser General Public License as
-; published by the Free Software Foundation, either version 3 of the
-; License, or (at your option) any later version.
-;
-; This program 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 Lesser General Public License
-; along with this program. If not, see .
-
-Include "../BlitzSteam.bb"
-
-;! Example is incomplete, I do not own a Steam Controller.
-
-; Initialize Steam before your next call to Graphics.
-If BS_SteamAPI_Init() = False Then
- RuntimeError "Steam: Failed to initialize!"
-EndIf
-
-Const FPS = 30
-Const FPS_MULT# = 1.0 / FPS
-
-; Demo Scene
-Graphics3D 1024, 768, 32, 2
-SetBuffer BackBuffer()
-
-Local demoTimer = CreateTimer(FPS)
-
-Local demoRoot = CreatePivot()
-
-Local demoCameraRoot = CreatePivot(demoRoot)
-Local demoCamera = CreateCamera(demoCameraRoot)
-MoveEntity demoCamera, 0, 0, -10
-
-Local demoCube = CreateCube(demoRoot)
-
-Local EndGame = False
-Repeat
- Cls
-
- ;! Update
- ; End on Escape
- EndGame = KeyHit(1)
-
- TurnEntity demoCube, 1 * FPS_MULT, 3 * FPS_MULT, 2.332 * FPS_MULT
-
- ;! Render 3D
- RenderWorld
-
- ;! Render 2D
- Text 0, 0, "Escape to Quit"
-
- ;! Update Window
- Flip 0
- WaitTimer(demoTimer)
-Until EndGame = True
-
-; Shut down Steam as the last action of your program.
-BS_SteamAPI_Shutdown()
-End
-;~IDEal Editor Parameters:
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+Include "../BlitzSteam.bb"
+
+;! Example is incomplete, I do not own a Steam Controller.
+
+; Initialize Steam before your next call to Graphics.
+If BS_SteamAPI_Init() = False Then
+ RuntimeError "Steam: Failed to initialize!"
+EndIf
+
+Const FPS = 30
+Const FPS_MULT# = 1.0 / FPS
+
+; Demo Scene
+Graphics3D 1024, 768, 32, 2
+SetBuffer BackBuffer()
+
+Local demoTimer = CreateTimer(FPS)
+
+Local demoRoot = CreatePivot()
+
+Local demoCameraRoot = CreatePivot(demoRoot)
+Local demoCamera = CreateCamera(demoCameraRoot)
+MoveEntity demoCamera, 0, 0, -10
+
+Local demoCube = CreateCube(demoRoot)
+
+Local EndGame = False
+Repeat
+ Cls
+
+ ;! Update
+ ; End on Escape
+ EndGame = KeyHit(1)
+
+ TurnEntity demoCube, 1 * FPS_MULT, 3 * FPS_MULT, 2.332 * FPS_MULT
+
+ ;! Render 3D
+ RenderWorld
+
+ ;! Render 2D
+ Text 0, 0, "Escape to Quit"
+
+ ;! Update Window
+ Flip 0
+ WaitTimer(demoTimer)
+Until EndGame = True
+
+; Shut down Steam as the last action of your program.
+BS_SteamAPI_Shutdown()
+End
+;~IDEal Editor Parameters:
;~C#Blitz3D
\ No newline at end of file
diff --git a/Resources/Examples/SteamHTMLSurface_Example.bb b/Resources/Examples/SteamHTMLSurface_Example.bb
index 9fcf963..36af349 100644
--- a/Resources/Examples/SteamHTMLSurface_Example.bb
+++ b/Resources/Examples/SteamHTMLSurface_Example.bb
@@ -1,381 +1,396 @@
-Include "../BlitzSteam.bb"
-
-;----------------------------------------------------------------
-;! Steam Stuff
-;----------------------------------------------------------------
-
-; SteamClient: WarningMessageHook
-Global Steam_WarningMessageHook_Callback = 0
-Function Steam_WarningMessageHook(bIsWarning%, pchMessageBuffer%)
- If Steam_WarningMessageHook_Callback = 0 Then
- Steam_WarningMessageHook_Callback = BP_GetFunctionPointer()
- Return
- EndIf
-
- ; Read Message from buffer
- Local msg$ = ""
- If bIsWarning = 1 Then
- msg = "[Warning]"
- Else
- msg = "[Info]"
- EndIf
- msg = msg + PeekMemoryStringC(pchMessageBuffer)
-
- DebugLog "[Steam]" + msg$
-End Function:Steam_WarningMessageHook(0, 0)
-Function PeekMemoryStringC(Memory%, Length%=-1)
- Local Ptr = Memory
- Local iChar = 0, tiChar = 0
- Local sOut$ = ""
-
- Repeat
- tiChar = PeekMemoryByte(Ptr)
-
- ; Advance memory, decrease Length
- Ptr = Ptr + 1
- Length = Length - 1
-
- If (tiChar = 0) Then
- Length = 0
- Else
- sOut = sOut + Chr(tiChar)
- EndIf
- Until Length = 0
-
- Return sOut
-End Function
-
-;----------------------------------------------------------------
-;! SteamBrowser (Image & Texture Drawing)
-;----------------------------------------------------------------
-Global SteamBrowser_Callback_BrowserReady_p = 0, SteamBrowser_Callback_BrowserReady_c = 0
-Global SteamBrowser_Callback_NeedsPaint_p = 0, SteamBrowser_Callback_NeedsPaint_c = 0
-Global SteamBrowser_Callback_StartRequest_p = 0, SteamBrowser_Callback_StartRequest_c = 0
-
-Type SteamBrowser
- Field Id%, lSteamAPICall%
- Field Size%[1] ;Width, Height
- Field URL$
-
- ; CEF Stuff
- Field UpdateRegion[3] ;X,Y,W,H
- Field Serial%, Scale#, ScrollX%, ScrollY%
-
- ; Image Based
- Field hImage%
-
- ; Texture Based
- Field hTexture%
-End Type
-
-Function SteamBrowser_Create.SteamBrowser(Width%, Height%, URL$="http://google.com/", UserAgent$="SteamBrowser", UserCSS$="")
- ; Create our Object
- Local SB.SteamBrowser = New SteamBrowser
- SB\Id = 0 ; Initialize to 0 until the Browser is ready.
- SB\Size[0] = Width
- SB\Size[1] = Height
- SB\URL = URL
- SB\lSteamAPICall = BS_ISteamHTMLSurface_CreateBrowser(BS_SteamHTMLSurface(), UserAgent, UserCSS)
-
- ; We need to register our callbacks, or nothing will work.
- BS_Callback_RegisterResult SteamBrowser_Callback_BrowserReady_c, SB\lSteamAPICall, BS_SteamHTMLSurface_BrowserReady ; Listen to the result of the last SteamAPICall.
- BS_Callback_Register SteamBrowser_Callback_NeedsPaint_c, BS_SteamHTMLSurface_NeedsPaint
- BS_Callback_Register SteamBrowser_Callback_StartRequest_c, BS_SteamHTMLSurface_StartRequest
-
- ; Image Based
- SB\hImage = CreateImage(SB\Size[0], SB\Size[1])
- ; Texture Based
- SB\hTexture = CreateTexture(SB\Size[0], SB\Size[1], 1+2)
-
- Return SB
-End Function
-
-Function SteamBrowser_Destroy(SB.SteamBrowser)
- ; Texture Based
- FreeTexture SB\hTexture
- ; Image Based
- FreeImage SB\hImage
-
- BS_ISteamHTMLSurface_RemoveBrowser BS_SteamHTMLSurface(), SB\Id
- Delete SB
-End Function
-
-Function SteamBrowser_Find.SteamBrowser(iId%, lSteamAPICall%)
- Local SB.SteamBrowser = Null
- ; Find by Id
- If iId <> 0
- For SB.SteamBrowser = Each SteamBrowser
- If (SB\Id = iId) Then
- Return SB
- EndIf
- Next
- EndIf
- ; Find by SteamAPICall
- If lSteamAPICall <> 0
- For SB.SteamBrowser = Each SteamBrowser
- If (SB\lSteamAPICall <> 0) And (BS_Long_Compare(lSteamAPICall, SB\lSteamAPICall) = 0) Then
- Return SB
- EndIf
- Next
- EndIf
- Return Null
-End Function
-
-Function SteamBrowser_SetSize(SB.SteamBrowser, Width%, Height%)
- SB\Size[0] = Width
- SB\Size[1] = Height
-
- ; Update Browser Size
- BS_ISteamHTMLSurface_SetSize BS_SteamHTMLSurface(), SB\Id, Width, Height
-
- ; Image Based
- FreeImage(SB\hImage)
- SB\hImage = CreateImage(Width, Height)
- ; Texture Based
- FreeTexture(SB\hTexture)
- SB\hTexture = CreateTexture(Width, Height, 1+2)
-End Function
-
-Function SteamBrowser_LoadUrl(SB.SteamBrowser, URL$, PostData$="")
- BS_ISteamHTMLSurface_LoadURL BS_SteamHTMLSurface(), SB\Id, URL, PostData
-End Function
-
-Function SteamBrowser_IsReady(SB.SteamBrowser)
- Return (SB\Id <> 0)
-End Function
-
-Function SteamBrowser_GetImageHandle(SB.SteamBrowser)
- Return SB\hImage
-End Function
-
-Function SteamBrowser_GetTextureHandle(SB.SteamBrowser)
- Return SB\hTexture
-End Function
-
-Function SteamBrowser_Callback_BrowserReady(pvParam%, bIOFailure, lSteamAPICall)
- If (SteamBrowser_Callback_BrowserReady_p = 0) Then
- SteamBrowser_Callback_BrowserReady_p = BP_GetFunctionPointer()
- SteamBrowser_Callback_BrowserReady_c = BS_Callback_New(SteamBrowser_Callback_BrowserReady_p)
- Return
- EndIf
-
- ; Search for a valid SteamBrowser object.
- Local SB.SteamBrowser = SteamBrowser_Find(0, lSteamAPICall)
- SB\Id = BS_Memory_PeekInt(pvParam, 0)
- SteamBrowser_SetSize(SB, SB\Size[0], SB\Size[1])
- SteamBrowser_LoadUrl(SB, SB\URL)
-
- ; Destroy our SteamAPICall pointer and clear the value.
- BS_Long_Destroy(SB\lSteamAPICall):SB\lSteamAPICall = 0
-End Function:SteamBrowser_Callback_BrowserReady(0, 0, 0)
-
-Function SteamBrowser_Callback_NeedsPaint(pvParam%, p2, p3)
- If (SteamBrowser_Callback_NeedsPaint_p = 0) Then
- SteamBrowser_Callback_NeedsPaint_p = BP_GetFunctionPointer()
- SteamBrowser_Callback_NeedsPaint_c = BS_Callback_New(SteamBrowser_Callback_NeedsPaint_p)
- Return
- EndIf
-
- ; Search for a valid SteamBrowser object.
- Local SB.SteamBrowser = SteamBrowser_Find(BS_Memory_PeekInt(pvParam, 0), 0)
-
- ; Parse Data from pvParam
- Local pBuffer, pW, pH, pUpdateX, pUpdateY, pUpdateW, pUpdateH, pScrollX, pScrollY, pScale#, pSerial
- pBuffer = BS_Memory_PeekInt(pvParam, 4)
- pW = BS_Memory_PeekInt(pvParam, 8)
- pH = BS_Memory_PeekInt(pvParam, 12)
- pUpdateX = BS_Memory_PeekInt(pvParam, 16)
- pUpdateY = BS_Memory_PeekInt(pvParam, 20)
- pUpdateW = BS_Memory_PeekInt(pvParam, 24)
- pUpdateH = BS_Memory_PeekInt(pvParam, 28)
- pScrollX = BS_Memory_PeekInt(pvParam, 32)
- pScrollY = BS_Memory_PeekInt(pvParam, 36)
- pScale = BS_Memory_PeekFloat(pvParam, 40)
- pSerial = BS_Memory_PeekInt(pvParam, 44)
-
- ; Assign to Object
- SB\UpdateRegion[0] = pUpdateX
- SB\UpdateRegion[1] = pUpdateY
- SB\UpdateRegion[2] = pUpdateW
- SB\UpdateRegion[3] = pUpdateH
- SB\Scale = pScale
- SB\ScrollX = pScrollX
- SB\ScrollY = pScrollY
- SB\Serial = pSerial
-
- ; Fix up Buffer Size (Always next bigger 16*n, for whatever reason (SIBLY WHAT DID YOU DO!?))
- Local nW = (16 * Ceil(pW / 16.0))
- ;DebugLog ImageWidth(SB\hImage) + ":" + ImageHeight(SB\hImage)
-
- ; Image Based
- Local hImageBuffer = ImageBuffer(SB\hImage)
- LockBuffer hImageBuffer
- BS_Helper_CopyMemoryIntMangle pBuffer, BS_Memory_PeekInt(hImageBuffer, 72), 0, pW, pH, nW, SB\Size[1], pUpdateX, pUpdateY, pUpdateW, pUpdateH
- UnlockBuffer hImageBuffer
-
- ; Texture Based (Identical)
- Local hTextureBuffer = ImageBuffer(SB\hImage)
- LockBuffer hTextureBuffer
- BS_Helper_CopyMemoryIntMangle pBuffer, BS_Memory_PeekInt(hTextureBuffer, 72), 0, pW, pH, nW, SB\Size[1], pUpdateX, pUpdateY, pUpdateW, pUpdateH
- UnlockBuffer hTextureBuffer
-
-
- ; pvParam Structure
- ;CALLBACK_MEMBER(0, HHTMLBrowser, unBrowserHandle) // the browser that needs the paint
- ;CALLBACK_MEMBER(1, const char *, pBGRA ) // a pointer to the B8G8R8A8 data for this surface, valid until SteamAPI_RunCallbacks is next called
- ;CALLBACK_MEMBER(2, uint32, unWide) // the total width of the pBGRA texture
- ;CALLBACK_MEMBER(3, uint32, unTall) // the total height of the pBGRA texture
- ;CALLBACK_MEMBER(4, uint32, unUpdateX) // the offset in X for the damage rect for this update
- ;CALLBACK_MEMBER(5, uint32, unUpdateY) // the offset in Y for the damage rect for this update
- ;CALLBACK_MEMBER(6, uint32, unUpdateWide) // the width of the damage rect for this update
- ;CALLBACK_MEMBER(7, uint32, unUpdateTall) // the height of the damage rect for this update
- ;CALLBACK_MEMBER(8, uint32, unScrollX) // the page scroll the browser was at when this texture was rendered
- ;CALLBACK_MEMBER(9, uint32, unScrollY) // the page scroll the browser was at when this texture was rendered
- ;CALLBACK_MEMBER(10, float, flPageScale) // the page scale factor on this page when rendered
- ;CALLBACK_MEMBER(11, uint32, unPageSerial) // incremented on each new page load, you can use this to reject draws while navigating to new pages
-End Function:SteamBrowser_Callback_NeedsPaint(0, 0, 0)
-
-Function SteamBrowser_Callback_StartRequest(pvParam%, p2, p3)
- If (SteamBrowser_Callback_StartRequest_p = 0) Then
- SteamBrowser_Callback_StartRequest_p = BP_GetFunctionPointer()
- SteamBrowser_Callback_StartRequest_c = BS_Callback_New(SteamBrowser_Callback_StartRequest_p)
- Return
- EndIf
-
- ; Search for a valid SteamBrowser object.
- Local SB.SteamBrowser = SteamBrowser_Find(BS_Memory_PeekInt(pvParam, 0), 0)
-
- ; Default to allow all requests. (Why not? For an Example, this is good enough.)
- ; Could implement a simple filter using a second type, but why don't you experiment a bit?
- BS_ISteamHTMLSurface_AllowStartRequest BS_SteamHTMLSurface(), SB\Id, True
-End Function:SteamBrowser_Callback_StartRequest(0, 0, 0)
-
-
-
-
-;----------------------------------------------------------------
-;! Example Code
-;----------------------------------------------------------------
-If BS_SteamAPI_Init() = 0 Then RuntimeError "Steam failed to initialize."
-
-; Steam: Hooks, Callbacks, CallResults
-BS_ISteamClient_SetWarningMessageHook BS_SteamClient(), Steam_WarningMessageHook_Callback
-
-; Steam: HTMLSurface API
-If BS_SteamHTMLSurface() = 0 Then RuntimeError "Steam: HTMLSurface API is not available."
-If BS_ISteamHTMLSurface_Init(BS_SteamHTMLSurface()) = 0 Then RuntimeError "Steam: HTMLSurface API did not want to be initialized?!"
-;BS_ISteamHTMLSurface_SetSize BS_SteamHTMLSurface(), 0, GraphicsWidth(), GraphicsHeight()
-
-Const FPS = 60
-Const FPS_MULT# = 1.0 / FPS
-
-; Demo Scene
-Graphics3D 1024, 768, 32, 2
-SetBuffer BackBuffer()
-
-Local demoTimer = CreateTimer(FPS)
-Local demoRoot = CreatePivot()
-Local demoCameraRoot = CreatePivot(demoRoot)
-Local demoCamera = CreateCamera(demoCameraRoot)
-MoveEntity demoCamera, 0, 0, -10
-Local demoCube = CreateCube(demoRoot)
-
-; Create a Browser
-Local myBrowser.SteamBrowser = SteamBrowser_Create(GraphicsWidth(), GraphicsHeight(), "http://store.steampowered.com/app/368720/")
-
-Local Mouse[3], MouseButton[3], Key[255]
-While Not KeyHit(1)
- Cls
-
- ; Only allow input when the browser is up to date.
- ;If (myBrowser\iLastDraw > myBrowser\iLastRequest) Then
- If True
- ; Mouse Input
- If Mouse[0] <> MouseX() Or Mouse[1] <> MouseY() Then
- Mouse[0] = MouseX()
- Mouse[1] = MouseY()
- BS_ISteamHTMLSurface_MouseMove BS_SteamHTMLSurface(), myBrowser\Id, MouseX(), MouseY()
- EndIf
- If Mouse[2] <> MouseZ() Then
- Mouse[2] = MouseZ()
- BS_ISteamHTMLSurface_MouseWheel BS_SteamHTMLSurface(), myBrowser\Id, MouseZSpeed()*30
- EndIf
-
- Local Button
- For Button = 1 To 3
- Local ButtonDown = MouseDown(Button)
- If MouseButton[Button] <> ButtonDown Then
- MouseButton[Button] = MouseDown(Button)
-
- If ButtonDown
- BS_ISteamHTMLSurface_MouseDown BS_SteamHTMLSurface(), myBrowser\Id, Button - 1
- Else
- BS_ISteamHTMLSurface_MouseUp BS_SteamHTMLSurface(), myBrowser\Id, Button - 1
- EndIf
- EndIf
- Next
-
- ; Keyboard
- Local Modifier = BS_EHTMLKeyModifiers_None
- If KeyDown(42) Or KeyDown(54) Then Modifier = Modifier Or BS_EHTMLKeyModifiers_ShiftDown
- If KeyDown(29) Or KeyDown(157) Or KeyDown(184) Then Modifier = Modifier Or BS_EHTMLKeyModifiers_CtrlDown
- If KeyDown(56) Or KeyDown(184) Then Modifier = Modifier Or BS_EHTMLKeyModifiers_AltDown
-
- Local VK
- For VK = 0 To 255
- Local SC = InputEx_User32_MapVirtualKeyEx(VK, 0, 0)
-
- Local KeyDownN = KeyDown(SC)
- If Key[VK] <> KeyDownN Then
- Key[VK] = KeyDownN
-
- If KeyDownN = 1 Then
- BS_ISteamHTMLSurface_KeyDown BS_SteamHTMLSurface(), myBrowser\Id, VK, Modifier
- Else
- BS_ISteamHTMLSurface_KeyUp BS_SteamHTMLSurface(), myBrowser\Id, VK, Modifier
- EndIf
- EndIf
- Next
- Local GetKeyC = GetKey()
- If GetKeyC
- BS_ISteamHTMLSurface_KeyChar BS_SteamHTMLSurface(), myBrowser\Id, GetKeyC, Modifier
- EndIf
-
- EndIf
-
- ; Steam: Run any Callbacks
- ; Q: Why before RenderWorld/Flip?
- ; A: If we did any changes, having them available before Rendering helps responsiveness.
- ; A one-frame Delay is noticeable, even to people claiming the eye only sees 30 fps.
- ; Please read a Biology book if you are one of those, it doesn't work like that.
- BS_SteamAPI_RunCallbacks()
-
- RenderWorld
-
- ;If (myBrowser\iLastDraw > myBrowser\iLastRequest) Then
- If Not KeyDown(57)
- DrawBlock SteamBrowser_GetImageHandle(myBrowser), 0, 0, 0
- Color 255, 0, 0
- Rect myBrowser\UpdateRegion[0],myBrowser\UpdateRegion[1],myBrowser\UpdateRegion[2],myBrowser\UpdateRegion[3], 0
- Else
- EntityTexture demoCube, SteamBrowser_GetTextureHandle(myBrowser)
- EndIf
- ;EndIf
-
- Flip
- WaitTimer demoTimer
-Wend
-
-; Destroy existing Browser
-SteamBrowser_Destroy(myBrowser):myBrowser = Null
-
-; Steam: HTMLSurface API
-BS_ISteamHTMLSurface_Shutdown(BS_SteamHTMLSurface())
-BS_SteamAPI_Shutdown()
-
-EndGraphics
-End
-
-;~IDEal Editor Parameters:
-;~F#8#19
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+Include "../BlitzSteam.bb"
+;----------------------------------------------------------------
+;! Steam Stuff
+;----------------------------------------------------------------
+
+; SteamClient: WarningMessageHook
+Global Steam_WarningMessageHook_Callback = 0
+Function Steam_WarningMessageHook(bIsWarning%, pchMessageBuffer%)
+ If Steam_WarningMessageHook_Callback = 0 Then
+ Steam_WarningMessageHook_Callback = BP_GetFunctionPointer()
+ Return
+ EndIf
+
+ ; Read Message from buffer
+ Local msg$ = ""
+ If bIsWarning = 1 Then
+ msg = "[Warning]"
+ Else
+ msg = "[Info]"
+ EndIf
+ msg = msg + PeekMemoryStringC(pchMessageBuffer)
+
+ DebugLog "[Steam]" + msg$
+End Function:Steam_WarningMessageHook(0, 0)
+Function PeekMemoryStringC(Memory%, Length%=-1)
+ Local Ptr = Memory
+ Local iChar = 0, tiChar = 0
+ Local sOut$ = ""
+
+ Repeat
+ tiChar = PeekMemoryByte(Ptr)
+
+ ; Advance memory, decrease Length
+ Ptr = Ptr + 1
+ Length = Length - 1
+
+ If (tiChar = 0) Then
+ Length = 0
+ Else
+ sOut = sOut + Chr(tiChar)
+ EndIf
+ Until Length = 0
+
+ Return sOut
+End Function
+
+;----------------------------------------------------------------
+;! SteamBrowser (Image & Texture Drawing)
+;----------------------------------------------------------------
+Global SteamBrowser_Callback_BrowserReady_p = 0, SteamBrowser_Callback_BrowserReady_c = 0
+Global SteamBrowser_Callback_NeedsPaint_p = 0, SteamBrowser_Callback_NeedsPaint_c = 0
+Global SteamBrowser_Callback_StartRequest_p = 0, SteamBrowser_Callback_StartRequest_c = 0
+
+Type SteamBrowser
+ Field Id%, lSteamAPICall%
+ Field Size%[1] ;Width, Height
+ Field URL$
+
+ ; CEF Stuff
+ Field UpdateRegion[3] ;X,Y,W,H
+ Field Serial%, Scale#, ScrollX%, ScrollY%
+
+ ; Image Based
+ Field hImage%
+
+ ; Texture Based
+ Field hTexture%
+End Type
+
+Function SteamBrowser_Create.SteamBrowser(Width%, Height%, URL$="http://google.com/", UserAgent$="SteamBrowser", UserCSS$="")
+ ; Create our Object
+ Local SB.SteamBrowser = New SteamBrowser
+ SB\Id = 0 ; Initialize to 0 until the Browser is ready.
+ SB\Size[0] = Width
+ SB\Size[1] = Height
+ SB\URL = URL
+ SB\lSteamAPICall = BS_ISteamHTMLSurface_CreateBrowser(BS_SteamHTMLSurface(), UserAgent, UserCSS)
+
+ ; We need to register our callbacks, or nothing will work.
+ BS_Callback_RegisterResult SteamBrowser_Callback_BrowserReady_c, SB\lSteamAPICall, BS_SteamHTMLSurface_BrowserReady ; Listen to the result of the last SteamAPICall.
+ BS_Callback_Register SteamBrowser_Callback_NeedsPaint_c, BS_SteamHTMLSurface_NeedsPaint
+ BS_Callback_Register SteamBrowser_Callback_StartRequest_c, BS_SteamHTMLSurface_StartRequest
+
+ ; Image Based
+ SB\hImage = CreateImage(SB\Size[0], SB\Size[1])
+ ; Texture Based
+ SB\hTexture = CreateTexture(SB\Size[0], SB\Size[1], 1+2)
+
+ Return SB
+End Function
+
+Function SteamBrowser_Destroy(SB.SteamBrowser)
+ ; Texture Based
+ FreeTexture SB\hTexture
+ ; Image Based
+ FreeImage SB\hImage
+
+ BS_ISteamHTMLSurface_RemoveBrowser BS_SteamHTMLSurface(), SB\Id
+ Delete SB
+End Function
+
+Function SteamBrowser_Find.SteamBrowser(iId%, lSteamAPICall%)
+ Local SB.SteamBrowser = Null
+ ; Find by Id
+ If iId <> 0
+ For SB.SteamBrowser = Each SteamBrowser
+ If (SB\Id = iId) Then
+ Return SB
+ EndIf
+ Next
+ EndIf
+ ; Find by SteamAPICall
+ If lSteamAPICall <> 0
+ For SB.SteamBrowser = Each SteamBrowser
+ If (SB\lSteamAPICall <> 0) And (BS_Long_Compare(lSteamAPICall, SB\lSteamAPICall) = 0) Then
+ Return SB
+ EndIf
+ Next
+ EndIf
+ Return Null
+End Function
+
+Function SteamBrowser_SetSize(SB.SteamBrowser, Width%, Height%)
+ SB\Size[0] = Width
+ SB\Size[1] = Height
+
+ ; Update Browser Size
+ BS_ISteamHTMLSurface_SetSize BS_SteamHTMLSurface(), SB\Id, Width, Height
+
+ ; Image Based
+ FreeImage(SB\hImage)
+ SB\hImage = CreateImage(Width, Height)
+ ; Texture Based
+ FreeTexture(SB\hTexture)
+ SB\hTexture = CreateTexture(Width, Height, 1+2)
+End Function
+
+Function SteamBrowser_LoadUrl(SB.SteamBrowser, URL$, PostData$="")
+ BS_ISteamHTMLSurface_LoadURL BS_SteamHTMLSurface(), SB\Id, URL, PostData
+End Function
+
+Function SteamBrowser_IsReady(SB.SteamBrowser)
+ Return (SB\Id <> 0)
+End Function
+
+Function SteamBrowser_GetImageHandle(SB.SteamBrowser)
+ Return SB\hImage
+End Function
+
+Function SteamBrowser_GetTextureHandle(SB.SteamBrowser)
+ Return SB\hTexture
+End Function
+
+Function SteamBrowser_Callback_BrowserReady(pvParam%, bIOFailure, lSteamAPICall)
+ If (SteamBrowser_Callback_BrowserReady_p = 0) Then
+ SteamBrowser_Callback_BrowserReady_p = BP_GetFunctionPointer()
+ SteamBrowser_Callback_BrowserReady_c = BS_Callback_New(SteamBrowser_Callback_BrowserReady_p)
+ Return
+ EndIf
+
+ ; Search for a valid SteamBrowser object.
+ Local SB.SteamBrowser = SteamBrowser_Find(0, lSteamAPICall)
+ SB\Id = BS_Memory_PeekInt(pvParam, 0)
+ SteamBrowser_SetSize(SB, SB\Size[0], SB\Size[1])
+ SteamBrowser_LoadUrl(SB, SB\URL)
+
+ ; Destroy our SteamAPICall pointer and clear the value.
+ BS_Long_Destroy(SB\lSteamAPICall):SB\lSteamAPICall = 0
+End Function:SteamBrowser_Callback_BrowserReady(0, 0, 0)
+
+Function SteamBrowser_Callback_NeedsPaint(pvParam%, p2, p3)
+ If (SteamBrowser_Callback_NeedsPaint_p = 0) Then
+ SteamBrowser_Callback_NeedsPaint_p = BP_GetFunctionPointer()
+ SteamBrowser_Callback_NeedsPaint_c = BS_Callback_New(SteamBrowser_Callback_NeedsPaint_p)
+ Return
+ EndIf
+
+ ; Search for a valid SteamBrowser object.
+ Local SB.SteamBrowser = SteamBrowser_Find(BS_Memory_PeekInt(pvParam, 0), 0)
+
+ ; Parse Data from pvParam
+ Local pBuffer, pW, pH, pUpdateX, pUpdateY, pUpdateW, pUpdateH, pScrollX, pScrollY, pScale#, pSerial
+ pBuffer = BS_Memory_PeekInt(pvParam, 4)
+ pW = BS_Memory_PeekInt(pvParam, 8)
+ pH = BS_Memory_PeekInt(pvParam, 12)
+ pUpdateX = BS_Memory_PeekInt(pvParam, 16)
+ pUpdateY = BS_Memory_PeekInt(pvParam, 20)
+ pUpdateW = BS_Memory_PeekInt(pvParam, 24)
+ pUpdateH = BS_Memory_PeekInt(pvParam, 28)
+ pScrollX = BS_Memory_PeekInt(pvParam, 32)
+ pScrollY = BS_Memory_PeekInt(pvParam, 36)
+ pScale = BS_Memory_PeekFloat(pvParam, 40)
+ pSerial = BS_Memory_PeekInt(pvParam, 44)
+
+ ; Assign to Object
+ SB\UpdateRegion[0] = pUpdateX
+ SB\UpdateRegion[1] = pUpdateY
+ SB\UpdateRegion[2] = pUpdateW
+ SB\UpdateRegion[3] = pUpdateH
+ SB\Scale = pScale
+ SB\ScrollX = pScrollX
+ SB\ScrollY = pScrollY
+ SB\Serial = pSerial
+
+ ; Fix up Buffer Size (Always next bigger 16*n, for whatever reason (SIBLY WHAT DID YOU DO!?))
+ Local nW = (16 * Ceil(pW / 16.0))
+ ;DebugLog ImageWidth(SB\hImage) + ":" + ImageHeight(SB\hImage)
+
+ ; Image Based
+ Local hImageBuffer = ImageBuffer(SB\hImage)
+ LockBuffer hImageBuffer
+ BS_Helper_CopyMemoryIntMangle pBuffer, BS_Memory_PeekInt(hImageBuffer, 72), 0, pW, pH, nW, SB\Size[1], pUpdateX, pUpdateY, pUpdateW, pUpdateH
+ UnlockBuffer hImageBuffer
+
+ ; Texture Based (Identical)
+ Local hTextureBuffer = ImageBuffer(SB\hImage)
+ LockBuffer hTextureBuffer
+ BS_Helper_CopyMemoryIntMangle pBuffer, BS_Memory_PeekInt(hTextureBuffer, 72), 0, pW, pH, nW, SB\Size[1], pUpdateX, pUpdateY, pUpdateW, pUpdateH
+ UnlockBuffer hTextureBuffer
+
+
+ ; pvParam Structure
+ ;CALLBACK_MEMBER(0, HHTMLBrowser, unBrowserHandle) // the browser that needs the paint
+ ;CALLBACK_MEMBER(1, const char *, pBGRA ) // a pointer to the B8G8R8A8 data for this surface, valid until SteamAPI_RunCallbacks is next called
+ ;CALLBACK_MEMBER(2, uint32, unWide) // the total width of the pBGRA texture
+ ;CALLBACK_MEMBER(3, uint32, unTall) // the total height of the pBGRA texture
+ ;CALLBACK_MEMBER(4, uint32, unUpdateX) // the offset in X for the damage rect for this update
+ ;CALLBACK_MEMBER(5, uint32, unUpdateY) // the offset in Y for the damage rect for this update
+ ;CALLBACK_MEMBER(6, uint32, unUpdateWide) // the width of the damage rect for this update
+ ;CALLBACK_MEMBER(7, uint32, unUpdateTall) // the height of the damage rect for this update
+ ;CALLBACK_MEMBER(8, uint32, unScrollX) // the page scroll the browser was at when this texture was rendered
+ ;CALLBACK_MEMBER(9, uint32, unScrollY) // the page scroll the browser was at when this texture was rendered
+ ;CALLBACK_MEMBER(10, float, flPageScale) // the page scale factor on this page when rendered
+ ;CALLBACK_MEMBER(11, uint32, unPageSerial) // incremented on each new page load, you can use this to reject draws while navigating to new pages
+End Function:SteamBrowser_Callback_NeedsPaint(0, 0, 0)
+
+Function SteamBrowser_Callback_StartRequest(pvParam%, p2, p3)
+ If (SteamBrowser_Callback_StartRequest_p = 0) Then
+ SteamBrowser_Callback_StartRequest_p = BP_GetFunctionPointer()
+ SteamBrowser_Callback_StartRequest_c = BS_Callback_New(SteamBrowser_Callback_StartRequest_p)
+ Return
+ EndIf
+
+ ; Search for a valid SteamBrowser object.
+ Local SB.SteamBrowser = SteamBrowser_Find(BS_Memory_PeekInt(pvParam, 0), 0)
+
+ ; Default to allow all requests. (Why not? For an Example, this is good enough.)
+ ; Could implement a simple filter using a second type, but why don't you experiment a bit?
+ BS_ISteamHTMLSurface_AllowStartRequest BS_SteamHTMLSurface(), SB\Id, True
+End Function:SteamBrowser_Callback_StartRequest(0, 0, 0)
+
+
+
+
+;----------------------------------------------------------------
+;! Example Code
+;----------------------------------------------------------------
+If BS_SteamAPI_Init() = 0 Then RuntimeError "Steam failed to initialize."
+
+; Steam: Hooks, Callbacks, CallResults
+BS_ISteamClient_SetWarningMessageHook BS_SteamClient(), Steam_WarningMessageHook_Callback
+
+; Steam: HTMLSurface API
+If BS_SteamHTMLSurface() = 0 Then RuntimeError "Steam: HTMLSurface API is not available."
+If BS_ISteamHTMLSurface_Init(BS_SteamHTMLSurface()) = 0 Then RuntimeError "Steam: HTMLSurface API did not want to be initialized?!"
+;BS_ISteamHTMLSurface_SetSize BS_SteamHTMLSurface(), 0, GraphicsWidth(), GraphicsHeight()
+
+Const FPS = 60
+Const FPS_MULT# = 1.0 / FPS
+
+; Demo Scene
+Graphics3D 1024, 768, 32, 2
+SetBuffer BackBuffer()
+
+Local demoTimer = CreateTimer(FPS)
+Local demoRoot = CreatePivot()
+Local demoCameraRoot = CreatePivot(demoRoot)
+Local demoCamera = CreateCamera(demoCameraRoot)
+MoveEntity demoCamera, 0, 0, -10
+Local demoCube = CreateCube(demoRoot)
+
+; Create a Browser
+Local myBrowser.SteamBrowser = SteamBrowser_Create(GraphicsWidth(), GraphicsHeight(), "http://store.steampowered.com/app/368720/")
+
+Local Mouse[3], MouseButton[3], Key[255]
+While Not KeyHit(1)
+ Cls
+
+ ; Only allow input when the browser is up to date.
+ ;If (myBrowser\iLastDraw > myBrowser\iLastRequest) Then
+ If True
+ ; Mouse Input
+ If Mouse[0] <> MouseX() Or Mouse[1] <> MouseY() Then
+ Mouse[0] = MouseX()
+ Mouse[1] = MouseY()
+ BS_ISteamHTMLSurface_MouseMove BS_SteamHTMLSurface(), myBrowser\Id, MouseX(), MouseY()
+ EndIf
+ If Mouse[2] <> MouseZ() Then
+ Mouse[2] = MouseZ()
+ BS_ISteamHTMLSurface_MouseWheel BS_SteamHTMLSurface(), myBrowser\Id, MouseZSpeed()*30
+ EndIf
+
+ Local Button
+ For Button = 1 To 3
+ Local ButtonDown = MouseDown(Button)
+ If MouseButton[Button] <> ButtonDown Then
+ MouseButton[Button] = MouseDown(Button)
+
+ If ButtonDown
+ BS_ISteamHTMLSurface_MouseDown BS_SteamHTMLSurface(), myBrowser\Id, Button - 1
+ Else
+ BS_ISteamHTMLSurface_MouseUp BS_SteamHTMLSurface(), myBrowser\Id, Button - 1
+ EndIf
+ EndIf
+ Next
+
+ ; Keyboard
+ Local Modifier = BS_EHTMLKeyModifiers_None
+ If KeyDown(42) Or KeyDown(54) Then Modifier = Modifier Or BS_EHTMLKeyModifiers_ShiftDown
+ If KeyDown(29) Or KeyDown(157) Or KeyDown(184) Then Modifier = Modifier Or BS_EHTMLKeyModifiers_CtrlDown
+ If KeyDown(56) Or KeyDown(184) Then Modifier = Modifier Or BS_EHTMLKeyModifiers_AltDown
+
+ Local VK
+ For VK = 0 To 255
+ Local SC = InputEx_User32_MapVirtualKeyEx(VK, 0, 0)
+
+ Local KeyDownN = KeyDown(SC)
+ If Key[VK] <> KeyDownN Then
+ Key[VK] = KeyDownN
+
+ If KeyDownN = 1 Then
+ BS_ISteamHTMLSurface_KeyDown BS_SteamHTMLSurface(), myBrowser\Id, VK, Modifier
+ Else
+ BS_ISteamHTMLSurface_KeyUp BS_SteamHTMLSurface(), myBrowser\Id, VK, Modifier
+ EndIf
+ EndIf
+ Next
+ Local GetKeyC = GetKey()
+ If GetKeyC
+ BS_ISteamHTMLSurface_KeyChar BS_SteamHTMLSurface(), myBrowser\Id, GetKeyC, Modifier
+ EndIf
+
+ EndIf
+
+ ; Steam: Run any Callbacks
+ ; Q: Why before RenderWorld/Flip?
+ ; A: If we did any changes, having them available before Rendering helps responsiveness.
+ ; A one-frame Delay is noticeable, even to people claiming the eye only sees 30 fps.
+ ; Please read a Biology book if you are one of those, it doesn't work like that.
+ BS_SteamAPI_RunCallbacks()
+
+ RenderWorld
+
+ ;If (myBrowser\iLastDraw > myBrowser\iLastRequest) Then
+ If Not KeyDown(57)
+ DrawBlock SteamBrowser_GetImageHandle(myBrowser), 0, 0, 0
+ Color 255, 0, 0
+ Rect myBrowser\UpdateRegion[0],myBrowser\UpdateRegion[1],myBrowser\UpdateRegion[2],myBrowser\UpdateRegion[3], 0
+ Else
+ EntityTexture demoCube, SteamBrowser_GetTextureHandle(myBrowser)
+ EndIf
+ ;EndIf
+
+ Flip
+ WaitTimer demoTimer
+Wend
+
+; Destroy existing Browser
+SteamBrowser_Destroy(myBrowser):myBrowser = Null
+
+; Steam: HTMLSurface API
+BS_ISteamHTMLSurface_Shutdown(BS_SteamHTMLSurface())
+BS_SteamAPI_Shutdown()
+
+EndGraphics
+End
+
+;~IDEal Editor Parameters:
+;~F#17#28
;~C#Blitz3D
\ No newline at end of file
diff --git a/Resources/Examples/SteamMatchmakingServers_Example.bb b/Resources/Examples/SteamMatchmakingServers_Example.bb
new file mode 100644
index 0000000..76b5b38
--- /dev/null
+++ b/Resources/Examples/SteamMatchmakingServers_Example.bb
@@ -0,0 +1,88 @@
+; BlitzSteam - Steam wrapper for Blitz
+; Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+;
+; This program is free software: you can redistribute it and/or modify
+; it under the terms of the GNU Lesser General Public License as
+; published by the Free Software Foundation, either version 3 of the
+; License, or (at your option) any later version.
+;
+; This program 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 Lesser General Public License
+; along with this program. If not, see .
+
+Include "../BlitzSteam.bb"
+
+;----------------------------------------------------------------
+;! Configuration
+;----------------------------------------------------------------
+Const APPID = 480 ; Test App / SpaceWar
+
+Const FRAMERATE = 60
+Const RESOLUTION_X = 1024
+Const RESOLUTION_Y = 768
+Const RESOLUTION_Z = 32
+Const RESOLUTION_MODE = 2
+
+;----------------------------------------------------------------
+;! Init Code
+;----------------------------------------------------------------
+Global Timer = CreateTimer(FRAMERATE)
+
+Global ServerListResponse_ServerResponded_p%:ServerListResponse_ServerResponded(0, 0)
+Global ServerListResponse_RefreshComplete_p%:ServerListResponse_RefreshComplete(0, 0)
+
+Graphics RESOLUTION_X, RESOLUTION_Y, RESOLUTION_Z, RESOLUTION_MODE
+SetBuffer BackBuffer()
+
+If Not BS_SteamAPI_Init() Then RuntimeError "Failed to initialize Steam!"
+
+;----------------------------------------------------------------
+;! Main Code
+;----------------------------------------------------------------
+Local Bank =CreateBank(1)
+Local pRequestServersResponse = BS_ISteamMatchmakingServerListResponse_New(ServerListResponse_ServerResponded_p, 0, ServerListResponse_RefreshComplete_p)
+Local hRequest = BS_ISteamMatchmakingServers_RequestInternetServerList(BS_SteamMatchmakingServers(), 480, Bank, 0, pRequestServersResponse)
+
+While Not KeyHit(1)
+ WaitTimer Timer
+ BS_SteamAPI_RunCallbacks()
+Wend
+
+BS_ISteamMatchmakingServers_ReleaseRequest(BS_SteamMatchmakingServers(), hRequest)
+BS_SteamAPI_Shutdown()
+
+;----------------------------------------------------------------
+;! Functions
+;----------------------------------------------------------------
+Function ServerListResponse_ServerResponded(hRequest%, iServer%)
+ If (Not ServerListResponse_ServerResponded_p)
+ ServerListResponse_ServerResponded_p = BP_GetFunctionPointer()
+ Return
+ EndIf
+ Print iServer
+End Function
+
+Function ServerListResponse_RefreshComplete(hRequest%, eMatchMakingServerResponse%)
+ If (Not ServerListResponse_RefreshComplete_p)
+ ServerListResponse_RefreshComplete_p = BP_GetFunctionPointer()
+ Return
+ EndIf
+
+ Select eMatchMakingServerResponse
+ Case BS_EMatchMakingServerResponse_ServerResponded
+ Print "Got Servers"
+ Case BS_EMatchMakingServerResponse_ServerFailedToRespond
+ Print "Server did not respond"
+ Case BS_EMatchMakingServerResponse_NoServersListedOnMasterServer
+ Print "No Servers listed for this game."
+ Default
+ Print "Unknown"
+ End Select
+End Function
+
+;~IDEal Editor Parameters:
+;~C#Blitz3D
\ No newline at end of file
diff --git a/Types/BlitzCallback.cpp b/Types/BlitzCallback.cpp
index 180adc8..849412e 100644
--- a/Types/BlitzCallback.cpp
+++ b/Types/BlitzCallback.cpp
@@ -1,266 +1,266 @@
-// BlitzSteam - Steam wrapper for Blitz
-// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU Lesser General Public License as
-// published by the Free Software Foundation, either version 3 of the
-// License, or (at your option) any later version.
-//
-// This program 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 Lesser General Public License
-// along with this program. If not, see .
-
-#include "BlitzCallback.h"
-
-void BlitzCallback::Initialize() {
-#define BlitzCallback_DefineSize(T) BlitzCallback::Sizes.emplace(T::k_iCallback, sizeof(T));
- // Do nothing if it was already done.
- if (BlitzCallback::Sizes.size() > 0)
- return;
-
- // Default to the size of the class itself if no callback id is given.
- BlitzCallback::Sizes.emplace(0, sizeof(BlitzCallback));
-
- // SteamAPI
- // SteamAppList
- BlitzCallback_DefineSize(SteamAppInstalled_t);
- BlitzCallback_DefineSize(SteamAppUninstalled_t);
- // SteamApps
- BlitzCallback_DefineSize(DlcInstalled_t);
- BlitzCallback_DefineSize(RegisterActivationCodeResponse_t);
- BlitzCallback_DefineSize(AppProofOfPurchaseKeyResponse_t);
- BlitzCallback_DefineSize(NewLaunchQueryParameters_t);
- // SteamController
- // SteamFriends
- BlitzCallback_DefineSize(PersonaStateChange_t);
- BlitzCallback_DefineSize(GameOverlayActivated_t);
- BlitzCallback_DefineSize(GameServerChangeRequested_t);
- BlitzCallback_DefineSize(GameLobbyJoinRequested_t);
- BlitzCallback_DefineSize(AvatarImageLoaded_t);
- BlitzCallback_DefineSize(ClanOfficerListResponse_t);
- BlitzCallback_DefineSize(FriendRichPresenceUpdate_t);
- BlitzCallback_DefineSize(GameRichPresenceJoinRequested_t);
- BlitzCallback_DefineSize(GameConnectedClanChatMsg_t);
- BlitzCallback_DefineSize(GameConnectedChatJoin_t);
- BlitzCallback_DefineSize(GameConnectedChatLeave_t);
- BlitzCallback_DefineSize(DownloadClanActivityCountsResult_t);
- BlitzCallback_DefineSize(JoinClanChatRoomCompletionResult_t);
- BlitzCallback_DefineSize(GameConnectedFriendChatMsg_t);
- BlitzCallback_DefineSize(FriendsGetFollowerCount_t);
- BlitzCallback_DefineSize(FriendsIsFollowing_t);
- BlitzCallback_DefineSize(FriendsEnumerateFollowingList_t);
- BlitzCallback_DefineSize(SetPersonaNameResponse_t);
- // SteamGameServer
- BlitzCallback_DefineSize(GSClientApprove_t);
- BlitzCallback_DefineSize(GSClientDeny_t);
- BlitzCallback_DefineSize(GSClientKick_t);
- BlitzCallback_DefineSize(GSClientAchievementStatus_t);
- BlitzCallback_DefineSize(GSPolicyResponse_t);
- BlitzCallback_DefineSize(GSGameplayStats_t);
- BlitzCallback_DefineSize(GSClientGroupStatus_t);
- BlitzCallback_DefineSize(GSReputation_t);
- BlitzCallback_DefineSize(AssociateWithClanResult_t);
- BlitzCallback_DefineSize(ComputeNewPlayerCompatibilityResult_t);
- // SteamGameServerStats
- BlitzCallback_DefineSize(GSStatsReceived_t);
- BlitzCallback_DefineSize(GSStatsStored_t);
- BlitzCallback_DefineSize(GSStatsUnloaded_t);
- // SteamHTMLSurface
- BlitzCallback_DefineSize(HTML_BrowserReady_t);
- // SteamHTTP
- BlitzCallback_DefineSize(HTTPRequestCompleted_t);
- BlitzCallback_DefineSize(HTTPRequestHeadersReceived_t);
- BlitzCallback_DefineSize(HTTPRequestDataReceived_t);
- // SteamInventory
- BlitzCallback_DefineSize(SteamInventoryResultReady_t);
- BlitzCallback_DefineSize(SteamInventoryFullUpdate_t);
- BlitzCallback_DefineSize(SteamInventoryDefinitionUpdate_t);
- // SteamMatchmaking
- // SteamMatchmakingServers
- // SteamMusic
- // SteamMusicRemote
- // SteamNetworking
- BlitzCallback_DefineSize(P2PSessionRequest_t);
- BlitzCallback_DefineSize(P2PSessionConnectFail_t);
- BlitzCallback_DefineSize(SocketStatusCallback_t);
-}
-
-std::map BlitzCallback::Sizes;
-
-BlitzCallback::BlitzCallback(BP_BlitzFunction3_t pFunctionPointer) {
- BlitzCallback::Initialize();
-
- // Initialize all values to 0.
- this->m_iCallback = 0;
- this->m_nCallbackFlags = 0;
- this->m_hSteamAPICall = 0;
-
- // Set function pointer.
- this->m_pFunctionPointer = pFunctionPointer;
-}
-
-BlitzCallback::~BlitzCallback() {
- // Unregister if we are still registered.
- this->UnregisterResult();
- this->Unregister();
-
- // Reset all variables to 0.
- this->m_iCallback = 0;
- this->m_nCallbackFlags = 0;
- this->m_hSteamAPICall = 0;
- this->m_pFunctionPointer = 0;
-}
-
-void BlitzCallback::Run(void *pvParam) {
- if (m_hSteamAPICall != 0)
- m_hSteamAPICall = 0; // Caller unregisters for us.
-
- BP_CallFunction3(m_pFunctionPointer, reinterpret_cast(pvParam), 0, 0);
-}
-
-void BlitzCallback::Run(void *pvParam, bool bIOFailure, SteamAPICall_t hSteamAPICall) {
- if (m_hSteamAPICall != 0)
- m_hSteamAPICall = 0; // Caller unregisters for us.
-
- BP_CallFunction3(m_pFunctionPointer, reinterpret_cast(pvParam), (bIOFailure ? 0 : 1), reinterpret_cast(&hSteamAPICall));
-}
-
-int BlitzCallback::GetCallbackSizeBytes() {
- return (BlitzCallback::Sizes.find(this->m_iCallback)->second);
-}
-
-void BlitzCallback::SetCallback(int32_t iCallback) {
- this->m_iCallback = iCallback;
-}
-
-int32_t BlitzCallback::GetCallback() {
- return this->m_iCallback;
-}
-
-void BlitzCallback::SetFunction(BP_BlitzFunction3_t pFunction) {
- this->m_pFunctionPointer = pFunction;
-}
-
-BP_BlitzFunction3_t BlitzCallback::GetFunction() {
- return this->m_pFunctionPointer;
-}
-
-bool BlitzCallback::IsRegistered() {
- return (this->m_nCallbackFlags & this->k_ECallbackFlagsRegistered) != 0;
-}
-
-void BlitzCallback::SetRegistered(bool bIsRegistered) {
- this->m_nCallbackFlags &= ~k_ECallbackFlagsRegistered;
- if (bIsRegistered)
- this->m_nCallbackFlags |= k_ECallbackFlagsRegistered;
-}
-
-bool BlitzCallback::IsGameServer() {
- return (this->m_nCallbackFlags & this->k_ECallbackFlagsGameServer) != 0;
-}
-
-void BlitzCallback::SetGameServer(bool bIsGameServer) {
- this->m_nCallbackFlags &= ~k_ECallbackFlagsGameServer;
- if (bIsGameServer)
- this->m_nCallbackFlags |= k_ECallbackFlagsGameServer;
-}
-
-void BlitzCallback::Register(uint32_t iCallback) {
- if (this->IsRegistered())
- this->Unregister();
-
- SteamAPI_RegisterCallback(this, iCallback);
- this->m_iCallback = iCallback;
-}
-
-void BlitzCallback::Unregister() {
- if (this->IsRegistered()) {
- SteamAPI_UnregisterCallback(this);
- this->m_iCallback = 0;
- }
-}
-
-void BlitzCallback::RegisterResult(SteamAPICall_t hSteamAPICall, uint32_t iCallback) {
- if (this->m_hSteamAPICall != 0)
- this->UnregisterResult();
-
- this->m_hSteamAPICall = hSteamAPICall;
- this->m_iCallback = iCallback;
-
- SteamAPI_RegisterCallResult(this, hSteamAPICall);
-}
-
-void BlitzCallback::UnregisterResult() {
- if (this->m_hSteamAPICall != 0) {
- SteamAPI_UnregisterCallResult(this, this->m_hSteamAPICall);
- this->m_hSteamAPICall = 0;
- this->m_iCallback = 0;
- }
-}
-
-//-----------------------------------------------------------------------------
-// C-Callables
-//-----------------------------------------------------------------------------
-DLL(BlitzCallback*) BS_Callback_New(BP_BlitzFunction3_t pFunctionPointer) {
- return new BlitzCallback(pFunctionPointer);
-}
-
-DLL(void) BS_Callback_Destroy(BlitzCallback* pCallback) {
- delete pCallback;
-}
-
-DLL(int32_t) BS_Callback_GetCallbackSizeBytes(BlitzCallback* pCallback) {
- return pCallback->GetCallbackSizeBytes();
-}
-
-DLL(void) BS_Callback_SetCallback(BlitzCallback* pCallback, int32_t iCallback) {
- pCallback->SetCallback(iCallback);
-}
-
-DLL(int32_t) BS_Callback_GetCallback(BlitzCallback* pCallback) {
- return pCallback->GetCallback();
-}
-
-DLL(void) BS_Callback_SetFunction(BlitzCallback* pCallback, BP_BlitzFunction3_t pFunction) {
- pCallback->SetFunction(pFunction);
-}
-
-DLL(BP_BlitzFunction3_t) BS_Callback_GetFunction(BlitzCallback* pCallback) {
- return pCallback->GetFunction();
-}
-
-DLL(int32_t) BS_Callback_IsRegistered(BlitzCallback* pCallback) {
- return pCallback->IsRegistered();
-}
-
-DLL(void) BS_Callback_SetRegistered(BlitzCallback* pCallback, int32_t bIsRegistered) {
- pCallback->SetRegistered(!!bIsRegistered);
-}
-
-DLL(int32_t) BS_Callback_IsGameServer(BlitzCallback* pCallback) {
- return pCallback->IsGameServer();
-}
-
-DLL(void) BS_Callback_SetGameServer(BlitzCallback* pCallback, int32_t bIsGameServer) {
- pCallback->SetGameServer(!!bIsGameServer);
-}
-
-DLL(void) BS_Callback_Register(BlitzCallback* pCallback, uint32_t iCallback) {
- pCallback->Register(iCallback);
-}
-
-DLL(void) BS_Callback_Unregister(BlitzCallback* pCallback) {
- pCallback->Unregister();
-}
-
-DLL(void) BS_Callback_RegisterResult(BlitzCallback* pCallback, SteamAPICall_t* pSteamAPICall, uint32_t iCallback) {
- pCallback->RegisterResult(*pSteamAPICall, iCallback);
-}
-
-DLL(void) BS_Callback_UnregisterResult(BlitzCallback* pCallback) {
- pCallback->UnregisterResult();
+// BlitzSteam - Steam wrapper for Blitz
+// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
+//
+// This program is free software: you can redistribute it and/or modify
+// it under the terms of the GNU Lesser General Public License as
+// published by the Free Software Foundation, either version 3 of the
+// License, or (at your option) any later version.
+//
+// This program 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 Lesser General Public License
+// along with this program. If not, see .
+
+#include "BlitzCallback.h"
+
+void BlitzCallback::Initialize() {
+#define BlitzCallback_DefineSize(T) BlitzCallback::Sizes.emplace(T::k_iCallback, sizeof(T));
+ // Do nothing if it was already done.
+ if (BlitzCallback::Sizes.size() > 0)
+ return;
+
+ // Default to the size of the class itself if no callback id is given.
+ BlitzCallback::Sizes.emplace(0, sizeof(BlitzCallback));
+
+ // SteamAPI
+ // SteamAppList
+ BlitzCallback_DefineSize(SteamAppInstalled_t);
+ BlitzCallback_DefineSize(SteamAppUninstalled_t);
+ // SteamApps
+ BlitzCallback_DefineSize(DlcInstalled_t);
+ BlitzCallback_DefineSize(RegisterActivationCodeResponse_t);
+ BlitzCallback_DefineSize(AppProofOfPurchaseKeyResponse_t);
+ BlitzCallback_DefineSize(NewLaunchQueryParameters_t);
+ // SteamController
+ // SteamFriends
+ BlitzCallback_DefineSize(PersonaStateChange_t);
+ BlitzCallback_DefineSize(GameOverlayActivated_t);
+ BlitzCallback_DefineSize(GameServerChangeRequested_t);
+ BlitzCallback_DefineSize(GameLobbyJoinRequested_t);
+ BlitzCallback_DefineSize(AvatarImageLoaded_t);
+ BlitzCallback_DefineSize(ClanOfficerListResponse_t);
+ BlitzCallback_DefineSize(FriendRichPresenceUpdate_t);
+ BlitzCallback_DefineSize(GameRichPresenceJoinRequested_t);
+ BlitzCallback_DefineSize(GameConnectedClanChatMsg_t);
+ BlitzCallback_DefineSize(GameConnectedChatJoin_t);
+ BlitzCallback_DefineSize(GameConnectedChatLeave_t);
+ BlitzCallback_DefineSize(DownloadClanActivityCountsResult_t);
+ BlitzCallback_DefineSize(JoinClanChatRoomCompletionResult_t);
+ BlitzCallback_DefineSize(GameConnectedFriendChatMsg_t);
+ BlitzCallback_DefineSize(FriendsGetFollowerCount_t);
+ BlitzCallback_DefineSize(FriendsIsFollowing_t);
+ BlitzCallback_DefineSize(FriendsEnumerateFollowingList_t);
+ BlitzCallback_DefineSize(SetPersonaNameResponse_t);
+ // SteamGameServer
+ BlitzCallback_DefineSize(GSClientApprove_t);
+ BlitzCallback_DefineSize(GSClientDeny_t);
+ BlitzCallback_DefineSize(GSClientKick_t);
+ BlitzCallback_DefineSize(GSClientAchievementStatus_t);
+ BlitzCallback_DefineSize(GSPolicyResponse_t);
+ BlitzCallback_DefineSize(GSGameplayStats_t);
+ BlitzCallback_DefineSize(GSClientGroupStatus_t);
+ BlitzCallback_DefineSize(GSReputation_t);
+ BlitzCallback_DefineSize(AssociateWithClanResult_t);
+ BlitzCallback_DefineSize(ComputeNewPlayerCompatibilityResult_t);
+ // SteamGameServerStats
+ BlitzCallback_DefineSize(GSStatsReceived_t);
+ BlitzCallback_DefineSize(GSStatsStored_t);
+ BlitzCallback_DefineSize(GSStatsUnloaded_t);
+ // SteamHTMLSurface
+ BlitzCallback_DefineSize(HTML_BrowserReady_t);
+ // SteamHTTP
+ BlitzCallback_DefineSize(HTTPRequestCompleted_t);
+ BlitzCallback_DefineSize(HTTPRequestHeadersReceived_t);
+ BlitzCallback_DefineSize(HTTPRequestDataReceived_t);
+ // SteamInventory
+ BlitzCallback_DefineSize(SteamInventoryResultReady_t);
+ BlitzCallback_DefineSize(SteamInventoryFullUpdate_t);
+ BlitzCallback_DefineSize(SteamInventoryDefinitionUpdate_t);
+ // SteamMatchmaking
+ // SteamMatchmakingServers
+ // SteamMusic
+ // SteamMusicRemote
+ // SteamNetworking
+ BlitzCallback_DefineSize(P2PSessionRequest_t);
+ BlitzCallback_DefineSize(P2PSessionConnectFail_t);
+ BlitzCallback_DefineSize(SocketStatusCallback_t);
+}
+
+std::map BlitzCallback::Sizes;
+
+BlitzCallback::BlitzCallback(BP_BlitzFunction3_t pFunctionPointer) {
+ BlitzCallback::Initialize();
+
+ // Initialize all values to 0.
+ this->m_iCallback = 0;
+ this->m_nCallbackFlags = 0;
+ this->m_hSteamAPICall = 0;
+
+ // Set function pointer.
+ this->m_pFunctionPointer = pFunctionPointer;
+}
+
+BlitzCallback::~BlitzCallback() {
+ // Unregister if we are still registered.
+ this->UnregisterResult();
+ this->Unregister();
+
+ // Reset all variables to 0.
+ this->m_iCallback = 0;
+ this->m_nCallbackFlags = 0;
+ this->m_hSteamAPICall = 0;
+ this->m_pFunctionPointer = 0;
+}
+
+void BlitzCallback::Run(void *pvParam) {
+ if (m_hSteamAPICall != 0)
+ m_hSteamAPICall = 0; // Caller unregisters for us.
+
+ BP_CallFunction3(m_pFunctionPointer, reinterpret_cast(pvParam), 0, 0);
+}
+
+void BlitzCallback::Run(void *pvParam, bool bIOFailure, SteamAPICall_t hSteamAPICall) {
+ if (m_hSteamAPICall != 0)
+ m_hSteamAPICall = 0; // Caller unregisters for us.
+
+ BP_CallFunction3(m_pFunctionPointer, reinterpret_cast(pvParam), (bIOFailure ? 0 : 1), reinterpret_cast(&hSteamAPICall));
+}
+
+int BlitzCallback::GetCallbackSizeBytes() {
+ return (BlitzCallback::Sizes.find(this->m_iCallback)->second);
+}
+
+void BlitzCallback::SetCallback(int32_t iCallback) {
+ this->m_iCallback = iCallback;
+}
+
+int32_t BlitzCallback::GetCallback() {
+ return this->m_iCallback;
+}
+
+void BlitzCallback::SetFunction(BP_BlitzFunction3_t pFunction) {
+ this->m_pFunctionPointer = pFunction;
+}
+
+BP_BlitzFunction3_t BlitzCallback::GetFunction() {
+ return this->m_pFunctionPointer;
+}
+
+bool BlitzCallback::IsRegistered() {
+ return (this->m_nCallbackFlags & this->k_ECallbackFlagsRegistered) != 0;
+}
+
+void BlitzCallback::SetRegistered(bool bIsRegistered) {
+ this->m_nCallbackFlags &= ~k_ECallbackFlagsRegistered;
+ if (bIsRegistered)
+ this->m_nCallbackFlags |= k_ECallbackFlagsRegistered;
+}
+
+bool BlitzCallback::IsGameServer() {
+ return (this->m_nCallbackFlags & this->k_ECallbackFlagsGameServer) != 0;
+}
+
+void BlitzCallback::SetGameServer(bool bIsGameServer) {
+ this->m_nCallbackFlags &= ~k_ECallbackFlagsGameServer;
+ if (bIsGameServer)
+ this->m_nCallbackFlags |= k_ECallbackFlagsGameServer;
+}
+
+void BlitzCallback::Register(uint32_t iCallback) {
+ if (this->IsRegistered())
+ this->Unregister();
+
+ SteamAPI_RegisterCallback(this, iCallback);
+ this->m_iCallback = iCallback;
+}
+
+void BlitzCallback::Unregister() {
+ if (this->IsRegistered()) {
+ SteamAPI_UnregisterCallback(this);
+ this->m_iCallback = 0;
+ }
+}
+
+void BlitzCallback::RegisterResult(SteamAPICall_t hSteamAPICall, uint32_t iCallback) {
+ if (this->m_hSteamAPICall != 0)
+ this->UnregisterResult();
+
+ this->m_hSteamAPICall = hSteamAPICall;
+ this->m_iCallback = iCallback;
+
+ SteamAPI_RegisterCallResult(this, hSteamAPICall);
+}
+
+void BlitzCallback::UnregisterResult() {
+ if (this->m_hSteamAPICall != 0) {
+ SteamAPI_UnregisterCallResult(this, this->m_hSteamAPICall);
+ this->m_hSteamAPICall = 0;
+ this->m_iCallback = 0;
+ }
+}
+
+//-----------------------------------------------------------------------------
+// C-Callables
+//-----------------------------------------------------------------------------
+DLL(BlitzCallback*) BS_Callback_New(BP_BlitzFunction3_t pFunctionPointer) {
+ return new BlitzCallback(pFunctionPointer);
+}
+
+DLL(void) BS_Callback_Destroy(BlitzCallback* pCallback) {
+ delete pCallback;
+}
+
+DLL(int32_t) BS_Callback_GetCallbackSizeBytes(BlitzCallback* pCallback) {
+ return pCallback->GetCallbackSizeBytes();
+}
+
+DLL(void) BS_Callback_SetCallback(BlitzCallback* pCallback, int32_t iCallback) {
+ pCallback->SetCallback(iCallback);
+}
+
+DLL(int32_t) BS_Callback_GetCallback(BlitzCallback* pCallback) {
+ return pCallback->GetCallback();
+}
+
+DLL(void) BS_Callback_SetFunction(BlitzCallback* pCallback, BP_BlitzFunction3_t pFunction) {
+ pCallback->SetFunction(pFunction);
+}
+
+DLL(BP_BlitzFunction3_t) BS_Callback_GetFunction(BlitzCallback* pCallback) {
+ return pCallback->GetFunction();
+}
+
+DLL(int32_t) BS_Callback_IsRegistered(BlitzCallback* pCallback) {
+ return pCallback->IsRegistered();
+}
+
+DLL(void) BS_Callback_SetRegistered(BlitzCallback* pCallback, int32_t bIsRegistered) {
+ pCallback->SetRegistered(!!bIsRegistered);
+}
+
+DLL(int32_t) BS_Callback_IsGameServer(BlitzCallback* pCallback) {
+ return pCallback->IsGameServer();
+}
+
+DLL(void) BS_Callback_SetGameServer(BlitzCallback* pCallback, int32_t bIsGameServer) {
+ pCallback->SetGameServer(!!bIsGameServer);
+}
+
+DLL(void) BS_Callback_Register(BlitzCallback* pCallback, uint32_t iCallback) {
+ pCallback->Register(iCallback);
+}
+
+DLL(void) BS_Callback_Unregister(BlitzCallback* pCallback) {
+ pCallback->Unregister();
+}
+
+DLL(void) BS_Callback_RegisterResult(BlitzCallback* pCallback, SteamAPICall_t* pSteamAPICall, uint32_t iCallback) {
+ pCallback->RegisterResult(*pSteamAPICall, iCallback);
+}
+
+DLL(void) BS_Callback_UnregisterResult(BlitzCallback* pCallback) {
+ pCallback->UnregisterResult();
}
\ No newline at end of file
diff --git a/Types/BlitzCallback.h b/Types/BlitzCallback.h
index 6709c9a..9425574 100644
--- a/Types/BlitzCallback.h
+++ b/Types/BlitzCallback.h
@@ -1,96 +1,96 @@
-// BlitzSteam - Steam wrapper for Blitz
-// Copyright (C) 2015 Xaymar (Michael Fabian Dirks)
-//
-// This program is free software: you can redistribute it and/or modify
-// it under the terms of the GNU Lesser General Public License as
-// published by the Free Software Foundation, either version 3 of the
-// License, or (at your option) any later version.
-//
-// This program 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 Lesser General Public License
-// along with this program. If not, see .
-
-#pragma once
-
-#include "BlitzSteamInternal.h"
-#include "../Helpers/BlitzPointer.h"
-
-#include
-#include
-#include